io_daemonizer 7.1 → 7.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/io_daemonizer.rb +4 -10
  3. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 659f573346f478e82593492d57366baa4f704cdad86495f71f9e14d3ab656e53
4
- data.tar.gz: '028c6285884760b1a2fa0330844128c1f63a713bc6efa1b2e6775f4ae3dcd64d'
3
+ metadata.gz: b77913ca0b5c285bb8a710fd00053a24866b53573ba9c41bb16ed602e31b38c4
4
+ data.tar.gz: 547656ffb02c86efcc71e61fc880b2123c107ec6db9b2f1096a7f1cef295ec70
5
5
  SHA512:
6
- metadata.gz: ebb22484722226e4761a4a29176f9b62f95513f693653c93adc7deb815f491b5b5711579c8ba29cf2810bb9c16f3e8539201cc287607ac4cf4e73074b35e21fc
7
- data.tar.gz: 3ee8bd1928ca173f3ccd5d9e10e47809bac6224f8e5d2eacece6aaf45d97328d5fcceae3201e3f7dbbe2d8df9059d5cf93dbd2401d117ae2223e224969a53d03
6
+ metadata.gz: 6fd051362f2c045038893605755df28027058bc6207a9e7c59f2637061b8dc38887677575303403430d5acc78480ac571bb2a30cc826cbc27c6d42e99ad7baff
7
+ data.tar.gz: 2b83f413fa0cdbf040844263e5b0ac0e6a0feb2f3742bd77cc796bc310cfcea7b40823ee8941462a3c2a9283e1d2043b22b14175b94287b86da5dfa8bf39f21c
data/io_daemonizer.rb CHANGED
@@ -1,4 +1,4 @@
1
- # io_daemonizer v.7.1 https://github.com/joeyschoblaska/io_daemonizer
1
+ # io_daemonizer v.7.2 https://github.com/joeyschoblaska/io_daemonizer
2
2
 
3
3
  require "json"
4
4
  require "shellwords"
@@ -131,15 +131,9 @@ class IODaemonizer
131
131
 
132
132
  def process_buffer
133
133
  parsed = JSON.parse(@buffer)
134
- key = parsed.keys[0]
135
- value = parsed.values[0]
136
-
137
- case key
138
- when "stdout"
139
- $stdout.write(value)
140
- when "stderr"
141
- $stderr.write(value)
142
- end
134
+
135
+ $stdout.write(parsed["stdout"]) if parsed["stdout"]
136
+ $stderr.write(parsed["stderr"]) if parsed["stderr"]
143
137
 
144
138
  @buffer = ""
145
139
  rescue JSON::ParserError
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: io_daemonizer
3
3
  version: !ruby/object:Gem::Version
4
- version: '7.1'
4
+ version: '7.2'
5
5
  platform: ruby
6
6
  authors:
7
7
  - Joey Schoblaska