Sha256: 51ecef3723c8eeb9ed5b7c95d41f7df70e04a7543911ceac2fffc80c97c3d247

Contents?: true

Size: 524 Bytes

Versions: 16

Compression:

Stored size: 524 Bytes

Contents

# frozen_string_literal: true

module Decidim
  module Core
    # This type represents the current user session.
    SessionType = GraphQL::ObjectType.define do
      name "Session"
      description "The current session"

      field :user, UserType, "The current user" do
        resolve ->(obj, _args, _ctx) { obj }
      end

      field :verifiedUserGroups, !types[!UserGroupType], "The current user verified user groups" do
        resolve ->(obj, _args, _ctx) { obj.user_groups.verified }
      end
    end
  end
end

Version data entries

16 entries across 16 versions & 1 rubygems

Version Path
decidim-core-0.14.4 app/types/decidim/core/session_type.rb
decidim-core-0.14.3 app/types/decidim/core/session_type.rb
decidim-core-0.14.2 app/types/decidim/core/session_type.rb
decidim-core-0.14.1 app/types/decidim/core/session_type.rb
decidim-core-0.13.1 app/types/decidim/core/session_type.rb
decidim-core-0.12.2 app/types/decidim/core/session_type.rb
decidim-core-0.13.0 app/types/decidim/core/session_type.rb
decidim-core-0.12.1 app/types/decidim/core/session_type.rb
decidim-core-0.13.0.pre1 app/types/decidim/core/session_type.rb
decidim-core-0.12.0 app/types/decidim/core/session_type.rb
decidim-core-0.11.2 app/types/decidim/core/session_type.rb
decidim-core-0.12.0.pre app/types/decidim/core/session_type.rb
decidim-core-0.11.1 app/types/decidim/core/session_type.rb
decidim-core-0.11.0.pre1 app/types/decidim/core/session_type.rb
decidim-core-0.10.1 app/types/decidim/core/session_type.rb
decidim-core-0.10.0 app/types/decidim/core/session_type.rb