mailjet 1.7.1 → 1.7.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/mailjet/connection.rb +3 -1
- data/lib/mailjet/resource.rb +2 -0
- data/lib/mailjet/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8196f5f49e3b7aa6766ad97b0e8a2346c4591f56f30a37e124a346ba46e06f3b
|
4
|
+
data.tar.gz: b7264d284ac5267785d26c0d8a14810f714ea74893f52eb8d82dc049347b1883
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e2c289c1757e6cbc7980296b2de8b9bf7052dbea80265e93d4131a8b8de720c11daa07e83d1ca0d42f4acbc8e637ed387130ca6cf12efbf896e089fb460cc4f8
|
7
|
+
data.tar.gz: 7502fade84d6f8690394c3a911dfdb48786d21a3414a79416436a04da69aba2f0450b35ea1912b586c69126d6b3052573c3b29a8f3929c969b3d97c3bb0d76ad
|
data/lib/mailjet/connection.rb
CHANGED
@@ -114,8 +114,10 @@ module Mailjet
|
|
114
114
|
return unless error_http_body
|
115
115
|
|
116
116
|
parsed_body = JSON.parse(error_http_body)
|
117
|
-
error_message = parsed_body
|
117
|
+
error_message = parsed_body.dig('Messages')&.first&.dig('Errors')&.first&.dig('ErrorMessage') || []
|
118
118
|
error_message.include?('is an invalid email address.')
|
119
|
+
rescue
|
120
|
+
false
|
119
121
|
end
|
120
122
|
|
121
123
|
end
|
data/lib/mailjet/resource.rb
CHANGED
@@ -28,6 +28,8 @@ module Mailjet
|
|
28
28
|
cattr_accessor :resource_path, :public_operations, :read_only, :filters, :resourceprop, :read_only_attributes, :action, :non_json_urls, :version
|
29
29
|
cattr_writer :connection
|
30
30
|
|
31
|
+
self.read_only_attributes = []
|
32
|
+
|
31
33
|
def self.connection(options = {})
|
32
34
|
class_variable_get(:@@connection) || default_connection(options)
|
33
35
|
end
|
data/lib/mailjet/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mailjet
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.7.
|
4
|
+
version: 1.7.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Tyler Nappy
|
@@ -11,7 +11,7 @@ authors:
|
|
11
11
|
autorequire:
|
12
12
|
bindir: bin
|
13
13
|
cert_chain: []
|
14
|
-
date:
|
14
|
+
date: 2023-02-15 00:00:00.000000000 Z
|
15
15
|
dependencies:
|
16
16
|
- !ruby/object:Gem::Dependency
|
17
17
|
name: activesupport
|