slnky 0.12.3 → 0.12.4

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: 1d2b6d1855cee1dee45d6f5feddfbb2ad70c0aea
4
- data.tar.gz: bae29e49910eb7c024598e074ea205dadd591b73
3
+ metadata.gz: 7cfe54e170e8248c911458a77b5d73c0c2c3640e
4
+ data.tar.gz: 285c09739886dc2383e5109e5d403a62e5261646
5
5
  SHA512:
6
- metadata.gz: efe3439c05da2860595e53b46c3bad0f70fcbdbde607f9af570f17185e1b77a6a6734e29934e70c0db85a933b93d01d501c06aba8c5624d5a041cbde346d0519
7
- data.tar.gz: 92aa52abd775fc2d2dc58c2a9e8453d24c8b0309ca02ab9aae25c93784ec7ddb6af27e408fbfa45585c021abd84a341cef4614230c3a901591d7305fbc5da940
6
+ metadata.gz: b8188e6017231bd395507e9fc6583277001bccf1bda16c78fe6e5a8600f2bb2deb804ae7b30c5158e66f706bf82e6ce8f351958e7ffdac3267b17dc925a0b54c
7
+ data.tar.gz: 614be9e8493f7b11dfa4f9e66d2bf30d7caa0357dfb9ffa50c26eaa518739cbc5991674b3c4d246779c2a0966bbd2ef35cf7588a5cea90832c960cd498c7f19b
data/lib/slnky/command.rb CHANGED
@@ -7,7 +7,7 @@ module Slnky
7
7
  module Command
8
8
  class Base
9
9
  def initialize
10
- @commands = self.class.commands||[]
10
+ @commands = self.class.commands
11
11
  end
12
12
 
13
13
  def handle(event, data, response=nil)
@@ -33,8 +33,12 @@ module Slnky
33
33
  end
34
34
 
35
35
  def handle_help(req, res, opts={})
36
- @commands.each do |command|
37
- log.info "#{name} #{command.name}: #{command.banner}"
36
+ if @commands && @commands.count > 0
37
+ @commands.each do |command|
38
+ log.info "#{name} #{command.name}: #{command.banner}"
39
+ end
40
+ else
41
+ log.info "#{name} has no additional commands"
38
42
  end
39
43
  end
40
44
 
data/lib/slnky/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Slnky
2
- VERSION = "0.12.3"
2
+ VERSION = "0.12.4"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: slnky
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.12.3
4
+ version: 0.12.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Shawn Catanzarite
@@ -288,7 +288,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
288
288
  version: '0'
289
289
  requirements: []
290
290
  rubyforge_project:
291
- rubygems_version: 2.4.7
291
+ rubygems_version: 2.4.8
292
292
  signing_key:
293
293
  specification_version: 4
294
294
  summary: core slnky lib and command line