magicmonkey 0.1.3 → 0.1.4

Sign up to get free protection for your applications and to get access to all the features.
@@ -261,11 +261,11 @@ module MagicMonkey
261
261
 
262
262
  private
263
263
 
264
- def self.get_port(port)
264
+ def self.get_port(port = nil)
265
265
  ports = Conf.ports
266
266
  return 3000 if ports.nil? || ports.empty?
267
267
  return false if ports.include?(port)
268
- return ports.max + 1 if port.nil?
268
+ return ((3000..5000).to_a - ports).first if port.nil?
269
269
  return port
270
270
  end
271
271
 
@@ -1,3 +1,3 @@
1
1
  module Magicmonkey
2
- VERSION = '0.1.3'
2
+ VERSION = '0.1.4'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: magicmonkey
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3
4
+ version: 0.1.4
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors: