wires 0.2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/wires/channel.rb +4 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 20865bb4eb206ffbcbbf1213093615337bcfddb8
|
4
|
+
data.tar.gz: 765995fb8eaa1bda0dbf45f9cfd87317c17cd3f5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cbd2971bd9d192b39cc20f97b3f301eb8175ac25cb1548db7f0e5ffeb1461cf777dcf377ed700d3694f80b9f39bc3017ccf0bf7cb236141cbde96b99e233776b
|
7
|
+
data.tar.gz: c85542dec7dabf46d30a7108dd71a83c2fd3791dc9f1956555c6fc4ed623f411e9bf878d772f6dac6344f3a1307787ec65cb81bef0635c4c81845ab03de7a1d2
|
data/lib/wires/channel.rb
CHANGED
@@ -47,7 +47,10 @@ module Wires
|
|
47
47
|
# Ensure that there is only one instance of Channel per name
|
48
48
|
@@new_lock = Mutex.new
|
49
49
|
def self.new(*args, &block)
|
50
|
-
|
50
|
+
(args.include? :recursion_guard) ?
|
51
|
+
(args.delete :recursion_guard) :
|
52
|
+
(@@channel_star[self.hub] ||= self.new('*', :recursion_guard))
|
53
|
+
|
51
54
|
@@new_lock.synchronize do
|
52
55
|
@@channel_hash[self.hub] ||= Hash.new
|
53
56
|
@@channel_hash[self.hub][args[0]] ||= super(*args, &block)
|