runify 1.0.0 → 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 217e728a08c8b966f6496dae4508a5445d5f815f
4
- data.tar.gz: 1805ac360c9c49d4b3377a18c063cc9899819b36
3
+ metadata.gz: 187e7fc5cca108c27ca05c678e722d902d950647
4
+ data.tar.gz: 3d2c96cf35ca337e49612c8b77c03b4ee8a5e085
5
5
  SHA512:
6
- metadata.gz: 0b8561d99a21caedc3f208c1c9e78731bde2593ca60969b53e4386de17ff7a50b63c338257304d2ae025864e7633ef620291a44d8405dfc358eae1d947179ad1
7
- data.tar.gz: 7a948c2fd02a219cba0b198cfbfb30a6945aab8e4cc6a1e9ca5ddd2b13fe21ca1c5cc174b9dba607cff0a18da3c7ede30d898f468d82ea0e5d2eaa06650d54c1
6
+ metadata.gz: 124eeac060119ad6cd9fba2d8b0620817b56b49e9c63ddabb6a5302641198783600e4b3b552ce3b4e6d4fe0f00700f3eb55f46f5d42ed09840ae1e327da65e62
7
+ data.tar.gz: 8f33aaddf7df64bd2b135a53363fb79d345fd33d4ea1d65fba6363ade000206b3f118c3756b1c47b6ad78e6fe0a6b7e918ebcdc4cf2f9bf098686fe181d4f5ea
@@ -14,7 +14,7 @@ module Runify
14
14
  # Startup:
15
15
  # Spawns a new Thread around the _run_ method.
16
16
  def startup
17
- return if @thread
17
+ return if defined?(@thread) && @thread
18
18
  @stop = nil
19
19
  @thread = Thread.new { run }
20
20
  end
@@ -23,7 +23,7 @@ module Runify
23
23
  # Requests the _run_ method to complete and blocks until it returns.
24
24
  def shutdown
25
25
  @stop = true
26
- @thread.join if @thread
26
+ @thread.join if defined?(@thread) && @thread
27
27
  @thread = nil
28
28
  end
29
29
 
@@ -5,5 +5,5 @@
5
5
  module Runify
6
6
 
7
7
  # Version
8
- VERSION = '1.0.0'
8
+ VERSION = '1.0.1'
9
9
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: runify
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Eresse
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-03-01 00:00:00.000000000 Z
11
+ date: 2017-06-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler