-
Notifications
You must be signed in to change notification settings - Fork 200
Closed
Description
I was testing the gem with a fresh Rails 5.1.0rc1 app. Whenever I try to save a model, it just rolls back and exits me out of console without any indication.
This didn't happen in the beta release of the rails though.
# frozen_string_literal: true
class Audience
belongs_to :client
extend Enumerize
enumerize :type, in: %i[T1 T2 T3]
end[1] pry(main)> Audience.create!(name: 'Some Audience', start_age: 18, end_age: 90, visitor_type: 'T2', min_spend_value: 150, client_id: 1)
Client Load (1.4ms) SELECT "clients".* FROM "clients" ORDER BY "clients"."id" ASC LIMIT $1 [["LIMIT", 1]]
(0.2ms) BEGIN
SQL (3.5ms) INSERT INTO "audiences" ("name", "visitor_type", "start_age", "end_age", "min_spend_value", "client_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["name", "Fourth Audience"], ["visitor_type", "T2"], ["start_age", 18], ["end_age", 90], ["min_spend_value", 150], ["client_id", 1], ["created_at", "2017-04-06 06:16:12.072160"], ["updated_at", "2017-04-06 06:16:12.072160"]]
(0.3ms) ROLLBACKHas it anything to do with the magic frozen string literal comment?
Metadata
Metadata
Assignees
Labels
No labels