git.iko.soy/typeable/mandrill
on master help sign in
Changed the mmsg_metadata and mmdt_values fields from MandrillVars to Object
7968381Bas van Dijk
README.md+2
@@ -12,6 +12,8 @@ the [Mandrill](http://mandrillapp.com) transactional email service.
12
12
13* Changed the MandrillHeaders type synonym from Value to Object.
13* Changed the MandrillHeaders type synonym from Value to Object.
14
14
15+* Changed the mmsg\_metadata and mmdt_values fields from MandrillVars to Object.
16+
15## Version 0.4.0.0
17## Version 0.4.0.0
16
18
17* Modified the `Base64ByteString` type to accept another constructor. This
19* Modified the `Base64ByteString` type to accept another constructor. This
src/Network/API/Mandrill.hs+1−1
@@ -88,7 +88,7 @@ emptyMessage f t = MandrillMessage {
88 , _mmsg_subaccount = Nothing
88 , _mmsg_subaccount = Nothing
89 , _mmsg_google_analytics_domains = []
89 , _mmsg_google_analytics_domains = []
90 , _mmsg_google_analytics_campaign = Nothing
90 , _mmsg_google_analytics_campaign = Nothing
91− , _mmsg_metadata = JSON.Null
91+ , _mmsg_metadata = H.empty
92 , _mmsg_recipient_metadata = []
92 , _mmsg_recipient_metadata = []
93 , _mmsg_attachments = []
93 , _mmsg_attachments = []
94 , _mmsg_images = []
94 , _mmsg_images = []
src/Network/API/Mandrill/Types.hs+3−3
@@ -190,7 +190,7 @@ deriveJSON defaultOptions { fieldLabelModifier = drop 6 } ''MandrillMergeVars
190--------------------------------------------------------------------------------
190--------------------------------------------------------------------------------
191data MandrillMetadata = MandrillMetadata {
191data MandrillMetadata = MandrillMetadata {
192 _mmdt_rcpt :: !T.Text
192 _mmdt_rcpt :: !T.Text
193− , _mmdt_values :: MandrillVars
193+ , _mmdt_values :: Object
194 } deriving Show
194 } deriving Show
195
195
196makeLenses ''MandrillMetadata
196makeLenses ''MandrillMetadata
@@ -296,7 +296,7 @@ data MandrillMessage = MandrillMessage {
296 -- ^ optional string indicating the value to set for the utm_campaign
296 -- ^ optional string indicating the value to set for the utm_campaign
297 -- tracking parameter. If this isn't provided the email's from address
297 -- tracking parameter. If this isn't provided the email's from address
298 -- will be used instead.
298 -- will be used instead.
299− , _mmsg_metadata :: MandrillVars
299+ , _mmsg_metadata :: Object
300 -- ^ metadata an associative array of user metadata. Mandrill will store
300 -- ^ metadata an associative array of user metadata. Mandrill will store
301 -- this metadata and make it available for retrieval.
301 -- this metadata and make it available for retrieval.
302 -- In addition, you can select up to 10 metadata fields to index
302 -- In addition, you can select up to 10 metadata fields to index
@@ -341,7 +341,7 @@ instance Arbitrary MandrillMessage where
341 <*> pure Nothing
341 <*> pure Nothing
342 <*> pure []
342 <*> pure []
343 <*> pure Nothing
343 <*> pure Nothing
344− <*> pure emptyObject
344+ <*> pure H.empty
345 <*> pure []
345 <*> pure []
346 <*> pure []
346 <*> pure []
347 <*> pure []
347 <*> pure []