Sha256: 05dedd59cd4e5b96fce73894f5954f131dafadc3149037c9f261ee7fba1c3052
Contents?: true
Size: 631 Bytes
Versions: 2
Compression:
Stored size: 631 Bytes
Contents
require File.join(File.dirname(__FILE__), 'le', 'host') require 'logger' module Le def self.new(token, local=false, debug_level = Logger::DEBUG) self.checkParams(token) host = Le::Host.new(token, local) logger = Logger.new(host) logger.level = debug_level if host.respond_to?(:formatter) logger.formatter = host.formatter end logger end def self.checkParams(token) # Check if the key is valid UUID format if (token =~ /\A(urn:uuid:)?[\da-f]{8}-([\da-f]{4}-){3}[\da-f]{12}\z/i) == nil puts "\nLE: It appears the LOGENTRIES_TOKEN you entered is invalid!\n" end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
le-2.1.6 | ./lib/le.rb |
le-2.1.4 | ./lib/le.rb |