1
0
mirror of https://github.com/LaCasemate/fab-manager.git synced 2024-12-01 12:24:28 +01:00
fab-manager/config/initializers/mail.rb

15 lines
548 B
Ruby
Raw Normal View History

2016-03-23 18:39:41 +01:00
require 'mail'
# This is trying to workaround an issue in `mail` gem
# Issue: https://github.com/mikel/mail/issues/912
#
# Since with current version (2.6.3) it is using `autoload`
# And as mentioned by a comment in the issue above
# It might not be thread-safe and
# might have problem in threaded environment like Sidekiq workers
#
# So we try to require the file manually here to avoid
# "uninitialized constant" error
#
# This is merely a workaround since
# it should fixed by not using the `autoload`
require 'mail/parsers/content_type_parser'