Sha256: 118811a2a83c4c965cb17ad00ed79bd9c3b7aff7f19ee68db115fab5b68f3778
Contents?: true
Size: 771 Bytes
Versions: 1
Compression:
Stored size: 771 Bytes
Contents
# frozen_string_literal: true module ConvenientService module Support module DependencyContainer module Commands class AssertValidScope < Support::Command ## # @!attribute [r] scope # @return [Symbol] # attr_reader :scope ## # @param scope [Symbol] # @return [void] # def initialize(scope:) @scope = scope end ## # @return [void] # @raise [ConvenientService::Support::DependencyContainer::Errors::InvalidScope] # def call raise Errors::InvalidScope.new(scope: scope) unless Constants::SCOPES.include?(scope) end end end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
convenient_service-0.12.0 | lib/convenient_service/support/dependency_container/commands/assert_valid_scope.rb |