sailthru-client 1.07 → 1.08

Sign up to get free protection for your applications and to get access to all the features.
Files changed (2) hide show
  1. data/lib/sailthru.rb +3 -5
  2. metadata +4 -4
data/lib/sailthru.rb CHANGED
@@ -7,7 +7,7 @@ require 'digest/md5'
7
7
 
8
8
  module Sailthru
9
9
 
10
- Version = VERSION = '1.07'
10
+ Version = VERSION = '1.08'
11
11
 
12
12
  class SailthruClientException < Exception
13
13
  end
@@ -125,10 +125,9 @@ module Sailthru
125
125
  # returns:
126
126
  # Hash, response data from server
127
127
  def send(template_name, email, vars={}, options = {}, schedule_time = nil)
128
- post = {}
128
+ post = options ? options : {}
129
129
  post[:template] = template_name
130
130
  post[:email] = email
131
- post[:options] = options
132
131
 
133
132
  if vars.length > 0
134
133
  post[:vars] = vars
@@ -142,10 +141,9 @@ module Sailthru
142
141
 
143
142
 
144
143
  def multi_send(template_name, emails, vars={}, options = {}, schedule_time = nil)
145
- post = {}
144
+ post = options ? options : {}
146
145
  post[:template] = template_name
147
146
  post[:email] = emails
148
- post[:options] = options
149
147
 
150
148
  if schedule_time != nil
151
149
  post[:schedule_time] = schedule_time
metadata CHANGED
@@ -1,12 +1,12 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sailthru-client
3
3
  version: !ruby/object:Gem::Version
4
- hash: 1
4
+ hash: 31
5
5
  prerelease:
6
6
  segments:
7
7
  - 1
8
- - 7
9
- version: "1.07"
8
+ - 8
9
+ version: "1.08"
10
10
  platform: ruby
11
11
  authors:
12
12
  - Prajwal Tuladhar
@@ -14,7 +14,7 @@ autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
16
 
17
- date: 2011-04-08 00:00:00 -04:00
17
+ date: 2011-04-26 00:00:00 -04:00
18
18
  default_executable:
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency