adhearsion-xmpp 1.0.2 → 1.1.0

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
  SHA1:
3
- metadata.gz: 471aeab4faa7b19b8eaafe5b4b3725da5877a145
4
- data.tar.gz: f4a596fad4a6eb235168a1513f13f0dce3242d77
3
+ metadata.gz: 7d7a5f904b09b6dc61b894152e751dbc5066d123
4
+ data.tar.gz: f0af67b95a5a494f75bd4c778a6468980c979920
5
5
  SHA512:
6
- metadata.gz: 00e18e12c76a4218d2f1cf5c52622e2437e7b8d963b09b9fd4337da1a0de00e45e7c4efa5116c339587c3c13f027c8accb099b99a3f4af6886d8614a716579b2
7
- data.tar.gz: 6321d090900c706fc2a95f16419e87a9262e7f4f4195077e595c765cc6b87d81e3e49f9c7dfe0727f33bcb162c916ea08df0bcbff68906b10fff1314727d6dd1
6
+ metadata.gz: d8e7e316fb25ea1459a683a9690223f9c7b04ef22adea05f66b08f7a788a9f653227a96c3c407d8ff059f4f9a710f40ef29b19e034adae22d0ae3b6d37cc461e
7
+ data.tar.gz: b9103fba24fc7a637f7d7549513f2d1c736781d1705dcff569ee6427b283a730e356f81a03b6852e8a5087fd6e1c6e0277e5057d38d10843231b3a350af5e23d
@@ -1,5 +1,8 @@
1
1
  # develop
2
2
 
3
+ # v1.1.0
4
+ * Feature: Connection can be disabled via configuration
5
+
3
6
  # v1.0.2
4
7
  * Bugfix: Reconnect after connection failures or connections dropping
5
8
 
@@ -22,7 +22,6 @@ Gem::Specification.new do |s|
22
22
  s.add_runtime_dependency "activesupport", [">= 3.0.10"]
23
23
  s.add_runtime_dependency "i18n", ">= 0.5.0"
24
24
  s.add_runtime_dependency "blather", "~> 1.0"
25
- s.add_runtime_dependency "jruby-openssl" if defined?(JRUBY_VERSION)
26
25
 
27
26
  s.add_development_dependency "rspec", "~> 2.7.0"
28
27
  s.add_development_dependency "rake", ">= 0.9.2"
@@ -4,6 +4,7 @@ module Adhearsion
4
4
 
5
5
  # Default configuration for XMPP connection.
6
6
  config :xmpp do
7
+ enabled true, :desc => "Enable or disable the connection", :transform => Proc.new { |v| v == 'true' }
7
8
  use_punchblock true, :desc => "Re-use Punchblock's XMPP connection. Boolean."
8
9
  jid nil, :desc => "Client/component JID to connect to. String."
9
10
  password nil, :desc => "Password identifier. String."
@@ -13,10 +14,12 @@ module Adhearsion
13
14
 
14
15
  # Include the XMPP service in plugins initialization process
15
16
  init :xmpp, :after => :punchblock do
16
- Adhearsion::XMPP.plugin = Adhearsion::XMPP::Plugin.new
17
- Adhearsion::XMPP.handlers.each do |handler|
18
- Adhearsion::XMPP.connection.instance_eval &handler
19
- end unless Adhearsion::XMPP.handlers.nil?
17
+ if config.enabled
18
+ Adhearsion::XMPP.plugin = Adhearsion::XMPP::Plugin.new
19
+ Adhearsion::XMPP.handlers.each do |handler|
20
+ Adhearsion::XMPP.connection.instance_eval &handler
21
+ end unless Adhearsion::XMPP.handlers.nil?
22
+ end
20
23
  end
21
24
 
22
25
  delegate :config, :to => self
@@ -1,5 +1,5 @@
1
1
  module Adhearsion
2
2
  class XMPP
3
- VERSION = "1.0.2"
3
+ VERSION = "1.1.0"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: adhearsion-xmpp
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.2
4
+ version: 1.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Juan de Bravo
@@ -11,7 +11,7 @@ authors:
11
11
  autorequire:
12
12
  bindir: bin
13
13
  cert_chain: []
14
- date: 2015-02-11 00:00:00.000000000 Z
14
+ date: 2015-12-23 00:00:00.000000000 Z
15
15
  dependencies:
16
16
  - !ruby/object:Gem::Dependency
17
17
  name: adhearsion