actionmailbox 6.1.4.2 → 6.1.7.7

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: dcd3370f56f156252d33325555ebd135692d5582ba78e882f94d89baac5b2534
4
- data.tar.gz: 498feca4c3d9312046540bfcc78b37504aa68c1b594238307cc1999904cd5c03
3
+ metadata.gz: 2183c41d939252abf42ff9b2685b1008d0b85b9045b31565df6dc91a4269b331
4
+ data.tar.gz: 67c85e330fb6bd42e59edaa1339b2dde309952395d4b0d6857be60472d567d51
5
5
  SHA512:
6
- metadata.gz: 942d09c4e665f2d9a6f15b3c76c56f9a9be1698270d452127e3978e27a4e2e29009025b6c417a2a57136df2ffde05b226ff29724221988dd0a4fef9effc7f3fe
7
- data.tar.gz: d811ec5034b5f49b780347218ff9f2d66356741b009f1e562d3e144c196b043b0930386497b8a5b492b3c2103a2bb9fe29143826e8318c1e731280fcffba186e
6
+ metadata.gz: 54f5aba6fa9233830518ba1161f7074b63a729d8d3e0112106d0ae6547d2ff0cac7984b1768653dd4f53759cdcafc56efb069e1e4d5c47630ed3ba5d0e02db99
7
+ data.tar.gz: d3536b752f7e11386094841238c45a6766e9fd3e3852a6f11502a98245d13ba955cd7bab06c9657fb63bdc7a4e04b26bec6266c1f733475dec38a1afc4eac927
data/CHANGELOG.md CHANGED
@@ -1,3 +1,98 @@
1
+ ## Rails 6.1.7.7 (February 21, 2024) ##
2
+
3
+ * No changes.
4
+
5
+
6
+ ## Rails 6.1.7.6 (August 22, 2023) ##
7
+
8
+ * No changes.
9
+
10
+
11
+ ## Rails 6.1.7.5 (August 22, 2023) ##
12
+
13
+ * No changes.
14
+
15
+
16
+ ## Rails 6.1.7.4 (June 26, 2023) ##
17
+
18
+ * No changes.
19
+
20
+
21
+ ## Rails 6.1.7.3 (March 13, 2023) ##
22
+
23
+ * No changes.
24
+
25
+
26
+ ## Rails 6.1.7.2 (January 24, 2023) ##
27
+
28
+ * No changes.
29
+
30
+
31
+ ## Rails 6.1.7.1 (January 17, 2023) ##
32
+
33
+ * No changes.
34
+
35
+
36
+ ## Rails 6.1.7 (September 09, 2022) ##
37
+
38
+ * No changes.
39
+
40
+
41
+ ## Rails 6.1.6.1 (July 12, 2022) ##
42
+
43
+ * No changes.
44
+
45
+
46
+ ## Rails 6.1.6 (May 09, 2022) ##
47
+
48
+ * No changes.
49
+
50
+
51
+ ## Rails 6.1.5.1 (April 26, 2022) ##
52
+
53
+ * No changes.
54
+
55
+
56
+ ## Rails 6.1.5 (March 09, 2022) ##
57
+
58
+ * Add `attachments` to the list of permitted parameters for inbound emails conductor.
59
+
60
+ When using the conductor to test inbound emails with attachments, this prevents an
61
+ unpermitted parameter warning in default configurations, and prevents errors for
62
+ applications that set:
63
+
64
+ ```ruby
65
+ config.action_controller.action_on_unpermitted_parameters = :raise
66
+ ```
67
+
68
+ *David Jones*, *Dana Henke*
69
+
70
+
71
+ ## Rails 6.1.4.7 (March 08, 2022) ##
72
+
73
+ * No changes.
74
+
75
+
76
+ ## Rails 6.1.4.6 (February 11, 2022) ##
77
+
78
+ * No changes.
79
+
80
+
81
+ ## Rails 6.1.4.5 (February 11, 2022) ##
82
+
83
+ * No changes.
84
+
85
+
86
+ ## Rails 6.1.4.4 (December 15, 2021) ##
87
+
88
+ * No changes.
89
+
90
+
91
+ ## Rails 6.1.4.3 (December 14, 2021) ##
92
+
93
+ * No changes.
94
+
95
+
1
96
  ## Rails 6.1.4.2 (December 14, 2021) ##
2
97
 
3
98
  * No changes.
data/MIT-LICENSE CHANGED
@@ -1,6 +1,6 @@
1
1
  MIT License
2
2
 
3
- Copyright (c) 2018-2020 Basecamp, LLC
3
+ Copyright (c) 2018-2022 Basecamp, LLC
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
@@ -79,13 +79,13 @@ module ActionMailbox
79
79
  def key
80
80
  if Rails.application.credentials.dig(:action_mailbox, :mailgun_api_key)
81
81
  ActiveSupport::Deprecation.warn(<<-MSG.squish)
82
- Rails.application.credentials.action_mailbox.api_key is deprecated and will be ignored in Rails 6.2.
82
+ Rails.application.credentials.action_mailbox.api_key is deprecated and will be ignored in Rails 7.0.
83
83
  Use Rails.application.credentials.action_mailbox.signing_key instead.
84
84
  MSG
85
85
  Rails.application.credentials.dig(:action_mailbox, :mailgun_api_key)
86
86
  elsif ENV["MAILGUN_INGRESS_API_KEY"]
87
87
  ActiveSupport::Deprecation.warn(<<-MSG.squish)
88
- The MAILGUN_INGRESS_API_KEY environment variable is deprecated and will be ignored in Rails 6.2.
88
+ The MAILGUN_INGRESS_API_KEY environment variable is deprecated and will be ignored in Rails 7.0.
89
89
  Use MAILGUN_INGRESS_SIGNING_KEY instead.
90
90
  MSG
91
91
  ENV["MAILGUN_INGRESS_API_KEY"]
@@ -20,14 +20,18 @@ module Rails
20
20
 
21
21
  private
22
22
  def new_mail
23
- Mail.new(params.require(:mail).permit(:from, :to, :cc, :bcc, :x_original_to, :in_reply_to, :subject, :body).to_h).tap do |mail|
23
+ Mail.new(mail_params.except(:attachments).to_h).tap do |mail|
24
24
  mail[:bcc]&.include_in_headers = true
25
- params[:mail][:attachments].to_a.each do |attachment|
25
+ mail_params[:attachments].to_a.each do |attachment|
26
26
  mail.add_file(filename: attachment.original_filename, content: attachment.read)
27
27
  end
28
28
  end
29
29
  end
30
30
 
31
+ def mail_params
32
+ params.require(:mail).permit(:from, :to, :cc, :bcc, :x_original_to, :in_reply_to, :subject, :body, attachments: [])
33
+ end
34
+
31
35
  def create_inbound_email(mail)
32
36
  ActionMailbox::InboundEmail.create_and_extract_message_id!(mail.to_s)
33
37
  end
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- require "mail"
3
+ require "action_mailbox/mail_with_error_handling"
4
4
 
5
5
  module ActionMailbox
6
6
  # The +InboundEmail+ is an Active Record that keeps a reference to the raw email stored in Active Storage
@@ -9,8 +9,8 @@ module ActionMailbox
9
9
  module VERSION
10
10
  MAJOR = 6
11
11
  MINOR = 1
12
- TINY = 4
13
- PRE = "2"
12
+ TINY = 7
13
+ PRE = "7"
14
14
 
15
15
  STRING = [MAJOR, MINOR, TINY, PRE].compact.join(".")
16
16
  end
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
- require "mail"
3
+ require "action_mailbox/mail_with_error_handling"
4
4
 
5
5
  # The hope is to upstream most of these basic additions to the Mail gem's Mail object. But until then, here they lay!
6
6
  Dir["#{File.expand_path(File.dirname(__FILE__))}/mail_ext/*"].each { |path| require "action_mailbox/mail_ext/#{File.basename(path)}" }
@@ -0,0 +1,10 @@
1
+ # frozen_string_literal: true
2
+
3
+ begin
4
+ require "mail"
5
+ rescue LoadError => error
6
+ if error.message.match?(/net\/smtp/)
7
+ $stderr.puts "You don't have net-smtp installed in your application. Please add it to your Gemfile and run bundle install"
8
+ raise
9
+ end
10
+ end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: actionmailbox
3
3
  version: !ruby/object:Gem::Version
4
- version: 6.1.4.2
4
+ version: 6.1.7.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - David Heinemeier Hansson
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2021-12-14 00:00:00.000000000 Z
12
+ date: 2024-02-21 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: activesupport
@@ -17,70 +17,70 @@ dependencies:
17
17
  requirements:
18
18
  - - '='
19
19
  - !ruby/object:Gem::Version
20
- version: 6.1.4.2
20
+ version: 6.1.7.7
21
21
  type: :runtime
22
22
  prerelease: false
23
23
  version_requirements: !ruby/object:Gem::Requirement
24
24
  requirements:
25
25
  - - '='
26
26
  - !ruby/object:Gem::Version
27
- version: 6.1.4.2
27
+ version: 6.1.7.7
28
28
  - !ruby/object:Gem::Dependency
29
29
  name: activerecord
30
30
  requirement: !ruby/object:Gem::Requirement
31
31
  requirements:
32
32
  - - '='
33
33
  - !ruby/object:Gem::Version
34
- version: 6.1.4.2
34
+ version: 6.1.7.7
35
35
  type: :runtime
36
36
  prerelease: false
37
37
  version_requirements: !ruby/object:Gem::Requirement
38
38
  requirements:
39
39
  - - '='
40
40
  - !ruby/object:Gem::Version
41
- version: 6.1.4.2
41
+ version: 6.1.7.7
42
42
  - !ruby/object:Gem::Dependency
43
43
  name: activestorage
44
44
  requirement: !ruby/object:Gem::Requirement
45
45
  requirements:
46
46
  - - '='
47
47
  - !ruby/object:Gem::Version
48
- version: 6.1.4.2
48
+ version: 6.1.7.7
49
49
  type: :runtime
50
50
  prerelease: false
51
51
  version_requirements: !ruby/object:Gem::Requirement
52
52
  requirements:
53
53
  - - '='
54
54
  - !ruby/object:Gem::Version
55
- version: 6.1.4.2
55
+ version: 6.1.7.7
56
56
  - !ruby/object:Gem::Dependency
57
57
  name: activejob
58
58
  requirement: !ruby/object:Gem::Requirement
59
59
  requirements:
60
60
  - - '='
61
61
  - !ruby/object:Gem::Version
62
- version: 6.1.4.2
62
+ version: 6.1.7.7
63
63
  type: :runtime
64
64
  prerelease: false
65
65
  version_requirements: !ruby/object:Gem::Requirement
66
66
  requirements:
67
67
  - - '='
68
68
  - !ruby/object:Gem::Version
69
- version: 6.1.4.2
69
+ version: 6.1.7.7
70
70
  - !ruby/object:Gem::Dependency
71
71
  name: actionpack
72
72
  requirement: !ruby/object:Gem::Requirement
73
73
  requirements:
74
74
  - - '='
75
75
  - !ruby/object:Gem::Version
76
- version: 6.1.4.2
76
+ version: 6.1.7.7
77
77
  type: :runtime
78
78
  prerelease: false
79
79
  version_requirements: !ruby/object:Gem::Requirement
80
80
  requirements:
81
81
  - - '='
82
82
  - !ruby/object:Gem::Version
83
- version: 6.1.4.2
83
+ version: 6.1.7.7
84
84
  - !ruby/object:Gem::Dependency
85
85
  name: mail
86
86
  requirement: !ruby/object:Gem::Requirement
@@ -142,6 +142,7 @@ files:
142
142
  - lib/action_mailbox/mail_ext/addresses.rb
143
143
  - lib/action_mailbox/mail_ext/from_source.rb
144
144
  - lib/action_mailbox/mail_ext/recipients.rb
145
+ - lib/action_mailbox/mail_with_error_handling.rb
145
146
  - lib/action_mailbox/relayer.rb
146
147
  - lib/action_mailbox/router.rb
147
148
  - lib/action_mailbox/router/route.rb
@@ -163,10 +164,11 @@ licenses:
163
164
  - MIT
164
165
  metadata:
165
166
  bug_tracker_uri: https://github.com/rails/rails/issues
166
- changelog_uri: https://github.com/rails/rails/blob/v6.1.4.2/actionmailbox/CHANGELOG.md
167
- documentation_uri: https://api.rubyonrails.org/v6.1.4.2/
167
+ changelog_uri: https://github.com/rails/rails/blob/v6.1.7.7/actionmailbox/CHANGELOG.md
168
+ documentation_uri: https://api.rubyonrails.org/v6.1.7.7/
168
169
  mailing_list_uri: https://discuss.rubyonrails.org/c/rubyonrails-talk
169
- source_code_uri: https://github.com/rails/rails/tree/v6.1.4.2/actionmailbox
170
+ source_code_uri: https://github.com/rails/rails/tree/v6.1.7.7/actionmailbox
171
+ rubygems_mfa_required: 'true'
170
172
  post_install_message:
171
173
  rdoc_options: []
172
174
  require_paths:
@@ -182,7 +184,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
182
184
  - !ruby/object:Gem::Version
183
185
  version: '0'
184
186
  requirements: []
185
- rubygems_version: 3.2.15
187
+ rubygems_version: 3.2.22
186
188
  signing_key:
187
189
  specification_version: 4
188
190
  summary: Inbound email handling framework.