matrix_dbus 2.0.0 → 2.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.en.md +4 -0
- data/README.md +4 -0
- data/exe/matrix-dbus +3 -1
- data/lib/matrix_dbus/dbus.rb +6 -0
- data/lib/matrix_dbus/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: fbec2e1c325bb53f32e41627da6c7c5c3f8169da
|
4
|
+
data.tar.gz: 9571f0bf0151ad5c2b4a8dcd4c999f10d7cf665b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cde018caa886277fcc95eef7982c287224552b945e37bd7024dead74654c84d5f119cb1d1142812d0446c4bcf11fbd4eea408e9b867576f54d960eb16bf9e522
|
7
|
+
data.tar.gz: 619d15770d9381baf976673349a2186d0fb036f1c808aeb65e4ca4fe54ec82fb90073dcd18c577438426a0f0d7f4ee172fef91cce8d74c28657ebcb04b341565
|
data/README.en.md
CHANGED
data/README.md
CHANGED
data/exe/matrix-dbus
CHANGED
@@ -4,7 +4,9 @@ require 'matrix_dbus'
|
|
4
4
|
Thread.abort_on_exception = true
|
5
5
|
|
6
6
|
def send_if_exist(obj, name, json)
|
7
|
-
|
7
|
+
return if json.nil?
|
8
|
+
return if json.empty?
|
9
|
+
obj.send name, JSON.pretty_generate(json)
|
8
10
|
end
|
9
11
|
|
10
12
|
def matrix2dbus(c, obj)
|
data/lib/matrix_dbus/dbus.rb
CHANGED
@@ -10,9 +10,15 @@ module MatrixDBus
|
|
10
10
|
|
11
11
|
def run
|
12
12
|
Thread.new { @matrix.run }
|
13
|
+
rescue RestClient::Exception => e
|
14
|
+
puts e
|
15
|
+
puts e.response.body
|
16
|
+
retry
|
13
17
|
end
|
14
18
|
|
15
19
|
def self.return(info)
|
20
|
+
return ['{}'] if info.nil?
|
21
|
+
return ['{}'] if info.empty?
|
16
22
|
[JSON.pretty_generate(info)]
|
17
23
|
end
|
18
24
|
|
data/lib/matrix_dbus/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: matrix_dbus
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.0.
|
4
|
+
version: 2.0.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- 71e6fd52
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-10-
|
11
|
+
date: 2017-10-29 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|