mailhandler 1.0.70 → 1.0.72

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: dbb6f095a2ff9b3b0ab32cee4f24945b5fe9e6a94ea250c73e385166d6cc1136
4
- data.tar.gz: fde7cbaf06445b3851eb6aae43187dd1da44ee2ff75d0e1162ad0f2f638f991e
3
+ metadata.gz: '08aed33b2ed897a008cc1b8c81f00f4243c63aac5a2de0f30f25aab2cef8414d'
4
+ data.tar.gz: b0d0d75e5eb5b0cb274da602cf73c3ee86416eb6c1127cd580e48453eb615d13
5
5
  SHA512:
6
- metadata.gz: bc2775e3ab6dfeba7b8ee4e7c87f20433be4b26ee9ce23c88929a389ac4b5eed4de231f8c2ad207429d865242d286386b100fe19dd7b632489010787582d3e00
7
- data.tar.gz: b9b8dcf8164a9ab0c8d6c4ad700b67912bd4af30b4497716b362ccb6bf42fc299a30cfaaeb2433dd9e42ec5aeb7c6f3929b2df63ca46873c9e2a3f321a954159
6
+ metadata.gz: 6d85939b67d64ba1e936de42581c190849c0be80125e342662597663dcbfd9e0d4bd04e4405501f6517d6fe2bc2250f21a7ed1f96a6c3ba0b946ec2f36484182
7
+ data.tar.gz: 10c9d1e259036557de7ec081f651d05dc83e1ff5114cba231e75a5c0c8a283e21f9420af661e5063ce0a2145d838ec4be8493c8dd7d1020f87d978a628cda895
@@ -49,7 +49,7 @@ module Mail
49
49
 
50
50
  # Start an IMAP session
51
51
  def connect(_config = Mail::Configuration.instance) # rubocop:disable all
52
- @imap_connection = Net::IMAP.new(settings[:address], settings[:port], settings[:enable_ssl], nil, false)
52
+ @imap_connection = Net::IMAP.new(settings[:address], **imap_parameters)
53
53
 
54
54
  if settings[:authentication].nil?
55
55
  imap_connection.login(settings[:user_name], settings[:password])
@@ -66,6 +66,12 @@ module Mail
66
66
 
67
67
  private
68
68
 
69
+ def imap_parameters
70
+ ssl_mode = settings[:enable_ssl] ? { verify_mode: OpenSSL::SSL::VERIFY_NONE } : false
71
+ port = settings[:port]
72
+ { port: port , ssl: ssl_mode }
73
+ end
74
+
69
75
  # fetch emails with different flag
70
76
  # to make it work with icloud
71
77
  FETCH_FLAG = {
@@ -20,5 +20,11 @@ module Mail
20
20
 
21
21
  settings[:return_response] ? response : self
22
22
  end
23
+
24
+ private
25
+
26
+ def dot_stuff(s)
27
+ s.sub(/\A\./, '..')
28
+ end
23
29
  end
24
30
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module MailHandler
4
- VERSION = '1.0.70'
4
+ VERSION = '1.0.72'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mailhandler
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.70
4
+ version: 1.0.72
5
5
  platform: ruby
6
6
  authors:
7
7
  - Igor Balos
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-01-02 00:00:00.000000000 Z
11
+ date: 2024-07-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: mail