Sha256: 27e50edc82d3af914a05fc9d81ea56537adff2134bac51f5fa66aa98ae5521e3
Contents?: true
Size: 752 Bytes
Versions: 12
Compression:
Stored size: 752 Bytes
Contents
# frozen_string_literal: true module Evostream module Events # Action inStreamClosed class InStreamClosed < Event def initialize(id_flux, config = {}) super(id_flux) @config = config end def execute super do |type_flux| klass = Evostream::Commands::Destroy.new(remove_config(type_flux)) @result = Evostream.send_command(klass.cmd) # yield if block_given? end end private attr_reader :config def remove_config(flux) if @config.empty? { group_name: "#{Evostream::Service.name}#{flux}", remove_hls_hds_files: 1 } else @config end end end end end
Version data entries
12 entries across 12 versions & 1 rubygems