mail_room 0.11.0 → 0.11.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 8937600a24f4f4321d47b0f1deb08d80a333785295b4e150fbe0e999e323ef3d
4
- data.tar.gz: a83dfa14d4b068d6147298cdb6eb94f06f247616abc2631392316beb3eb79002
3
+ metadata.gz: 19af01fda7b569451fb82914c0f0e58ea2cfac4e4e1ac9c4d9a9675639f17ce8
4
+ data.tar.gz: 8136e87b65e4ba1601b11067206fc723096d7b9b3db54d17b749642c4c00f84c
5
5
  SHA512:
6
- metadata.gz: bd3e703bca57dae0549cbc8cb51ab5fb63f5ad49ceb721b4567758c10779949c540c8bce100cbc656b0a420e761513a0d15716107e4443cfb1f1e35053fd60fe
7
- data.tar.gz: 5e873c3fdf2ee82aec7d7ec4485223c386c3ed0e274113670ca5c949467d6abb7551d8777d601d9e3f3a14bfceff44c24fbdb46cb4bdf084a0124ce63215fd67
6
+ metadata.gz: 490ad54534238439f740a917d3b010a19e5b710dcdcc87b265b48f9e7df1632a27cd492ee626872db8e7fe44f96dab56deb770bc394a9a4748089f80eefed5ce
7
+ data.tar.gz: c73bcb68f9a2b2bb3a9002a8a6eff236876bfbd2d22a9c83272f748796247aa9582e4a87153425ecd773b4e848e768addb74bf3bbbbf611cde199b5a76c43f7e
@@ -31,7 +31,7 @@ jobs:
31
31
  - '3.0'
32
32
  - '2.7'
33
33
  steps:
34
- - uses: actions/checkout@v3
34
+ - uses: actions/checkout@v4
35
35
  - name: Set up Ruby ${{ matrix.ruby-version }}
36
36
  uses: ruby/setup-ruby@v1
37
37
  with:
@@ -43,7 +43,7 @@ jobs:
43
43
  rubocop:
44
44
  runs-on: ubuntu-latest
45
45
  steps:
46
- - uses: actions/checkout@v3
46
+ - uses: actions/checkout@v4
47
47
  - name: Set up Ruby ${{ matrix.ruby-version }}
48
48
  uses: ruby/setup-ruby@v1
49
49
  with:
data/CHANGELOG.md CHANGED
@@ -1,3 +1,7 @@
1
+ ## mail_room 0.11.1 ##
2
+
3
+ https://github.com/tpitale/mail_room/compare/v0.11.0...v0.11.1
4
+
1
5
  ## mail_room 0.11.0 ##
2
6
 
3
7
  https://github.com/tpitale/mail_room/compare/v0.10.1...v0.11.0
@@ -71,7 +71,7 @@ module MailRoom
71
71
  connection = Faraday.new
72
72
 
73
73
  if @delivery_options.token_auth?
74
- connection.token_auth @delivery_options.token
74
+ config_token_auth(connection)
75
75
  elsif @delivery_options.basic_auth?
76
76
  config_basic_auth(connection)
77
77
  end
@@ -101,6 +101,18 @@ module MailRoom
101
101
  request.headers[@delivery_options.jwt.header] = @delivery_options.jwt.token
102
102
  end
103
103
 
104
+ def config_token_auth(connection)
105
+ # connection.token_auth was removed in Faraday v2 in favor of connection.request(:authorization, 'Token', token)
106
+ if defined?(connection.token_auth)
107
+ connection.token_auth @delivery_options.token
108
+ else
109
+ connection.request(
110
+ :authorization, 'Token',
111
+ @delivery_options.token
112
+ )
113
+ end
114
+ end
115
+
104
116
  def config_basic_auth(connection)
105
117
  if defined?(connection.basic_auth)
106
118
  connection.basic_auth(
@@ -1,4 +1,4 @@
1
1
  module MailRoom
2
2
  # Current version of MailRoom gem
3
- VERSION = "0.11.0"
3
+ VERSION = "0.11.1"
4
4
  end
data/mail_room.gemspec CHANGED
@@ -24,7 +24,7 @@ Gem::Specification.new do |gem|
24
24
  gem.add_development_dependency "rake"
25
25
  gem.add_development_dependency "rspec", "~> 3.9"
26
26
  gem.add_development_dependency "rubocop", "~> 1.11"
27
- gem.add_development_dependency "mocha", "~> 1.11"
27
+ gem.add_development_dependency "mocha", "~> 2.0"
28
28
  gem.add_development_dependency "simplecov"
29
29
 
30
30
  # for testing delivery methods
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mail_room
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.11.0
4
+ version: 0.11.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tony Pitale
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-02-04 00:00:00.000000000 Z
11
+ date: 2024-02-28 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: net-imap
@@ -106,14 +106,14 @@ dependencies:
106
106
  requirements:
107
107
  - - "~>"
108
108
  - !ruby/object:Gem::Version
109
- version: '1.11'
109
+ version: '2.0'
110
110
  type: :development
111
111
  prerelease: false
112
112
  version_requirements: !ruby/object:Gem::Requirement
113
113
  requirements:
114
114
  - - "~>"
115
115
  - !ruby/object:Gem::Version
116
- version: '1.11'
116
+ version: '2.0'
117
117
  - !ruby/object:Gem::Dependency
118
118
  name: simplecov
119
119
  requirement: !ruby/object:Gem::Requirement