notifiable-core 0.1.1 → 0.1.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: bb8e7ef4c2bba4b56bca98fcc78ae71dfe12bd5fd078d00313719c4c8fb610c3
4
- data.tar.gz: 9e8d57d563ce194c9f1adbd7dd282f54d5db3fefa7bad75b811c34c4ff7cddba
3
+ metadata.gz: 984fc84ebc977d8c8fa0cb5e4136619c0701efd5c122dad1e3e2f7d67e256b9c
4
+ data.tar.gz: 1966c421a2c3f7f146b1b6232755e59d0011276e92fbde6299056399eddf1e9a
5
5
  SHA512:
6
- metadata.gz: 6791ee36ff374ace0d46a84fda750e0f014805600f196aaff07cd3b48a6b0a00b93b4ac39b03fafffb8eda9ffcea853998e2630efb7db3dbcf97c44f17dc1d16
7
- data.tar.gz: 22360a63ad3b19ad05e28c994fb688216a94bf4b1091dddd478a5227cd92e7e6f3af7baf0abe7383d358426f17eb8050b09eda1a57c651444b3c1f4ebfcb585c
6
+ metadata.gz: 4d6a71178f525ba4565ff504baf9691865229339f8142cfd5be0d1611e794b5aff17b2ec0cbf6a2e4ff06ca6bf11beefb15e099ba648171fdad9c011ea974b3b
7
+ data.tar.gz: d3281079cf2d906c29df4f1d9eb9d7ab7eb48643c8777483bfc934796f56d7afccc89d027b985020093f64f5779adf237432c30ca88bbf3037187de79841f09b
@@ -1,4 +1,5 @@
1
1
  # frozen_string_literal: true
2
+ require 'logger'
2
3
 
3
4
  module Notifiable
4
5
  class NotifierBase
@@ -29,6 +30,14 @@ module Notifiable
29
30
  end
30
31
 
31
32
  protected
33
+
34
+ def logger
35
+ if defined?(Rails)
36
+ Rails.logger
37
+ else
38
+ @logger ||= Logger.new(STDOUT)
39
+ end
40
+ end
32
41
 
33
42
  def flush; end
34
43
 
@@ -1,3 +1,3 @@
1
1
  module Notifiable
2
- VERSION = '0.1.1'.freeze
2
+ VERSION = '0.1.2'.freeze
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: notifiable-core
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matt Brooke-Smith