Class: Jobs::Base
- Inherits:
-
Object
- Object
- Jobs::Base
- Defined in:
- app/models/jobs/base.rb
Direct Known Subclasses
DeferredDispatch, DeleteAccount, FetchProfilePhoto, FetchPublicPosts, FetchWebfinger, GatherOEmbedData, HttpMulti, Mail::AlsoCommented, Mail::CommentOnPost, Mail::ConfirmEmail, Mail::InviteUserByEmail, Mail::Liked, Mail::Mentioned, Mail::PrivateMessage, Mail::Reshared, Mail::StartedSharing, NotifyLocalUsers, PostToService, ProcessPhoto, PublishToHub, Receive, ReceiveEncryptedSalmon, ReceiveLocalBatch, ReceiveUnencryptedSalmon, ResendInvitation, ResetPassword
Constant Summary
- DUMB_ERROR_MESSAGES =
TODO these should be subclassed real exceptions
[ "Contact required unless request", "Relayable object, but no parent object found" ]
Class Method Summary (collapse)
Class Method Details
+ (Object) suppress_annoying_errors(&block)
14 15 16 17 18 19 20 21 22 23 |
# File 'app/models/jobs/base.rb', line 14 def self.(&block) begin yield rescue => e Rails.logger.info("error in job: #{e.}") unless DUMB_ERROR_MESSAGES.include?(e.) raise e end end end |