Class: MessageLog
- Inherits:
-
ActiveRecord::Base
- Object
- ActiveRecord::Base
- MessageLog
- Defined in:
- app/models/message_log.rb
Constant Summary collapse
- ERROR_REPORTS_ATTR =
%w(message_id bounced? final_recipient action error_status diagnostic_code retryable?)
- SERIALIZED_ATTR =
%w(from to delivery_method delivery_handler errors)
- OTHER_ATTR =
%w(subject content_type charset perform_deliveries)
- ALL_ATTR =
ERROR_REPORTS_ATTR + SERIALIZED_ATTR + OTHER_ATTR
Class Method Summary collapse
Instance Method Summary collapse
-
#delivery_handler ⇒ Object
TODO: Find out why it can’t get serialized.
-
#errors ⇒ Object
HACK: bypass the ActiveModel::Errors.
Class Method Details
.instance_method_already_implemented?(method_name) ⇒ Boolean
30 31 32 33 |
# File 'app/models/message_log.rb', line 30 def instance_method_already_implemented?(method_name) return true if method_name == 'errors' super end |
Instance Method Details
#delivery_handler ⇒ Object
TODO: Find out why it can’t get serialized.
19 20 21 |
# File 'app/models/message_log.rb', line 19 def delivery_handler attributes['delivery_handler'].constantize end |
#errors ⇒ Object
HACK: bypass the ActiveModel::Errors
25 26 27 |
# File 'app/models/message_log.rb', line 25 def errors attributes['errors'] end |