ex_cite 1.1.0 → 1.2.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -134,7 +134,7 @@ module ExCite
134
134
  # The callback url is defined here
135
135
  def callback
136
136
  # Starts with current url minus the querystring..
137
- callback = "#{export_citations_url}?"
137
+ callback = "#{export_citations_url.gsub(/https*/, @push_to.protocol.to_s)}?"
138
138
  citations.collect do |citation|
139
139
  # then adds a resource key for each cached resource
140
140
  callback += (!citation.respond_to? :new_record || citation.new_record?) ? "resource_key[]=#{citation.resource_key}&" : "id[]=#{citation.id}&"
@@ -2,7 +2,7 @@ module ExCite
2
2
  # Citation class, holds data from format and/or resource key
3
3
  class PushFormat
4
4
  # Required fields
5
- attr_accessor :name, :to_format, :action, :template, :url, :method, :enctype, :element_name
5
+ attr_accessor :name, :to_format, :action, :template, :url, :method, :enctype, :element_name, :protocol
6
6
  def initialize args = {}
7
7
  self.name = (args[:name] or 'Service')
8
8
  self.to_format = args[:to_format]
@@ -12,6 +12,7 @@ module ExCite
12
12
  self.method = (args[:method] or "POST")
13
13
  self.enctype = (args[:enctype] or "application/x-www-form-urlencoded")
14
14
  self.element_name = (args[:element_name] or "data")
15
+ self.protocol = (args[:protocol] or :http)
15
16
  end
16
17
  end
17
18
  end
@@ -1,3 +1,3 @@
1
1
  module ExCite
2
- VERSION = "1.1.0"
2
+ VERSION = "1.2.1"
3
3
  end