Sha256: 9ad1a153c5fafae8469185fd0c427ca5435f7dda699d2590bdf25ec3340d4f5c

Contents?: true

Size: 510 Bytes

Versions: 2

Compression:

Stored size: 510 Bytes

Contents

# frozen_string_literal: true

require_relative 'space_association_methods_factory'

module Contentful
  module Management
    # Wrapper for User API for usage from within Space
    # @private
    class SpaceUserMethodsFactory
      attr_reader :space

      def initialize(space)
        @space = space
      end

      def find(id)
        User.find(space.client, space.id, nil, id)
      end

      def all(params = {})
        User.all(space.client, space.id, nil, params, nil)
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
contentful-management-3.10.0 lib/contentful/management/space_user_methods_factory.rb
contentful-management-3.9.0 lib/contentful/management/space_user_methods_factory.rb