Sha256: bef856aa2d02525071f5bf44664b3087ef72c5ffbc3d52cd74a3d897c1ea7d43

Contents?: true

Size: 590 Bytes

Versions: 7

Compression:

Stored size: 590 Bytes

Contents

# frozen_string_literal: true

module Dry
  module System
    module Plugins
      # @api public
      module Notifications
        # @api private
        def self.extended(system)
          system.after(:configure, &:register_notifications)
        end

        # @api private
        def self.dependencies
          {"dry-monitor": "dry/monitor"}
        end

        # @api private
        def register_notifications
          return self if registered?(:notifications)

          register(:notifications, Monitor::Notifications.new(config.name))
        end
      end
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
dry-system-1.1.1 lib/dry/system/plugins/notifications.rb
dry-system-1.1.0 lib/dry/system/plugins/notifications.rb
dry-system-1.1.0.beta2 lib/dry/system/plugins/notifications.rb
dry-system-1.1.0.beta1 lib/dry/system/plugins/notifications.rb
dry-system-1.0.1 lib/dry/system/plugins/notifications.rb
dry-system-1.0.0 lib/dry/system/plugins/notifications.rb
dry-system-1.0.0.rc1 lib/dry/system/plugins/notifications.rb