Sha256: 200acfb09d07c958dd907aa63b6e33bc0d47371a76207cc51b567380a9eb83ef

Contents?: true

Size: 655 Bytes

Versions: 4

Compression:

Stored size: 655 Bytes

Contents

# frozen_string_literal: true

module Trusona
  module Resources
    #
    ## A Device User Binding Activation
    class DeviceUserBindingActivation < BaseResource
      include Trusona::Resources::Validators
      include Trusona::Helpers::KeyNormalizer
      attr_reader :id, :active

      def initialize(params = {})
        normalized_params = normalize_keys(params)
        @id = normalized_params[:id]
        @active = normalized_params[:active]

        @params = normalized_params
        raise Trusona::InvalidResourceError unless validate
      end

      def validate
        return false unless @id

        true
      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
trusona-2.5.3 lib/trusona/resources/device_user_binding_activation.rb
trusona-2.5.2 lib/trusona/resources/device_user_binding_activation.rb
trusona-2.5.1 lib/trusona/resources/device_user_binding_activation.rb
trusona-2.5.0 lib/trusona/resources/device_user_binding_activation.rb