authorizer/server/graph/generated/generated.go

8368 lines
228 KiB
Go
Raw Normal View History

// Code generated by github.com/99designs/gqlgen, DO NOT EDIT.
package generated
import (
"bytes"
"context"
"errors"
"strconv"
"sync"
"sync/atomic"
"github.com/99designs/gqlgen/graphql"
"github.com/99designs/gqlgen/graphql/introspection"
2021-07-23 16:27:44 +00:00
"github.com/authorizerdev/authorizer/server/graph/model"
gqlparser "github.com/vektah/gqlparser/v2"
"github.com/vektah/gqlparser/v2/ast"
)
// region ************************** generated!.gotpl **************************
// NewExecutableSchema creates an ExecutableSchema from the ResolverRoot interface.
func NewExecutableSchema(cfg Config) graphql.ExecutableSchema {
return &executableSchema{
resolvers: cfg.Resolvers,
directives: cfg.Directives,
complexity: cfg.Complexity,
}
}
type Config struct {
Resolvers ResolverRoot
Directives DirectiveRoot
Complexity ComplexityRoot
}
type ResolverRoot interface {
Mutation() MutationResolver
Query() QueryResolver
}
2021-07-28 06:23:37 +00:00
type DirectiveRoot struct {
}
type ComplexityRoot struct {
AuthResponse struct {
AccessToken func(childComplexity int) int
ExpiresAt func(childComplexity int) int
Message func(childComplexity int) int
User func(childComplexity int) int
}
2022-01-17 07:42:46 +00:00
Env struct {
2021-12-31 11:33:37 +00:00
AdminSecret func(childComplexity int) int
AllowedOrigins func(childComplexity int) int
AppURL func(childComplexity int) int
AuthorizerURL func(childComplexity int) int
CookieName func(childComplexity int) int
DefaultRoles func(childComplexity int) int
DisableBasicAuthentication func(childComplexity int) int
DisableEmailVerification func(childComplexity int) int
DisableLoginPage func(childComplexity int) int
DisableMagicLinkLogin func(childComplexity int) int
FacebookClientID func(childComplexity int) int
FacebookClientSecret func(childComplexity int) int
GithubClientID func(childComplexity int) int
GithubClientSecret func(childComplexity int) int
GoogleClientID func(childComplexity int) int
GoogleClientSecret func(childComplexity int) int
JwtRoleClaim func(childComplexity int) int
JwtSecret func(childComplexity int) int
JwtType func(childComplexity int) int
OrganizationLogo func(childComplexity int) int
OrganizationName func(childComplexity int) int
ProtectedRoles func(childComplexity int) int
RedisURL func(childComplexity int) int
ResetPasswordURL func(childComplexity int) int
Roles func(childComplexity int) int
SMTPHost func(childComplexity int) int
SMTPPassword func(childComplexity int) int
2021-12-31 11:33:37 +00:00
SMTPPort func(childComplexity int) int
SMTPUsername func(childComplexity int) int
2021-12-31 11:33:37 +00:00
SenderEmail func(childComplexity int) int
}
Error struct {
Message func(childComplexity int) int
Reason func(childComplexity int) int
}
Meta struct {
IsBasicAuthenticationEnabled func(childComplexity int) int
IsEmailVerificationEnabled func(childComplexity int) int
IsFacebookLoginEnabled func(childComplexity int) int
IsGithubLoginEnabled func(childComplexity int) int
IsGoogleLoginEnabled func(childComplexity int) int
IsMagicLinkLoginEnabled func(childComplexity int) int
Version func(childComplexity int) int
}
Mutation struct {
2021-12-30 04:31:51 +00:00
AdminLogin func(childComplexity int, params model.AdminLoginInput) int
2021-12-31 17:36:06 +00:00
AdminLogout func(childComplexity int) int
AdminSignup func(childComplexity int, params model.AdminSignupInput) int
2021-08-06 13:47:52 +00:00
DeleteUser func(childComplexity int, params model.DeleteUserInput) int
ForgotPassword func(childComplexity int, params model.ForgotPasswordInput) int
Login func(childComplexity int, params model.LoginInput) int
Logout func(childComplexity int) int
MagicLinkLogin func(childComplexity int, params model.MagicLinkLoginInput) int
ResendVerifyEmail func(childComplexity int, params model.ResendVerifyEmailInput) int
2021-08-07 08:41:26 +00:00
ResetPassword func(childComplexity int, params model.ResetPasswordInput) int
Signup func(childComplexity int, params model.SignUpInput) int
2022-01-17 07:42:46 +00:00
UpdateEnv func(childComplexity int, params model.UpdateEnvInput) int
UpdateProfile func(childComplexity int, params model.UpdateProfileInput) int
UpdateUser func(childComplexity int, params model.UpdateUserInput) int
VerifyEmail func(childComplexity int, params model.VerifyEmailInput) int
}
Query struct {
2021-12-30 04:31:51 +00:00
AdminSession func(childComplexity int) int
2022-01-17 07:42:46 +00:00
Env func(childComplexity int) int
Meta func(childComplexity int) int
Profile func(childComplexity int) int
Session func(childComplexity int, roles []string) int
Users func(childComplexity int) int
VerificationRequests func(childComplexity int) int
2021-07-15 09:43:00 +00:00
}
Response struct {
Message func(childComplexity int) int
}
2021-07-12 18:22:16 +00:00
User struct {
Birthdate func(childComplexity int) int
CreatedAt func(childComplexity int) int
Email func(childComplexity int) int
EmailVerified func(childComplexity int) int
FamilyName func(childComplexity int) int
Gender func(childComplexity int) int
GivenName func(childComplexity int) int
ID func(childComplexity int) int
MiddleName func(childComplexity int) int
Nickname func(childComplexity int) int
PhoneNumber func(childComplexity int) int
PhoneNumberVerified func(childComplexity int) int
Picture func(childComplexity int) int
PreferredUsername func(childComplexity int) int
Roles func(childComplexity int) int
SignupMethods func(childComplexity int) int
UpdatedAt func(childComplexity int) int
}
2021-07-12 18:22:16 +00:00
VerificationRequest struct {
CreatedAt func(childComplexity int) int
Email func(childComplexity int) int
Expires func(childComplexity int) int
ID func(childComplexity int) int
Identifier func(childComplexity int) int
Token func(childComplexity int) int
UpdatedAt func(childComplexity int) int
}
}
type MutationResolver interface {
Signup(ctx context.Context, params model.SignUpInput) (*model.AuthResponse, error)
Login(ctx context.Context, params model.LoginInput) (*model.AuthResponse, error)
MagicLinkLogin(ctx context.Context, params model.MagicLinkLoginInput) (*model.Response, error)
2021-07-15 09:43:00 +00:00
Logout(ctx context.Context) (*model.Response, error)
UpdateProfile(ctx context.Context, params model.UpdateProfileInput) (*model.Response, error)
VerifyEmail(ctx context.Context, params model.VerifyEmailInput) (*model.AuthResponse, error)
ResendVerifyEmail(ctx context.Context, params model.ResendVerifyEmailInput) (*model.Response, error)
ForgotPassword(ctx context.Context, params model.ForgotPasswordInput) (*model.Response, error)
2021-08-07 08:41:26 +00:00
ResetPassword(ctx context.Context, params model.ResetPasswordInput) (*model.Response, error)
2021-08-06 13:47:52 +00:00
DeleteUser(ctx context.Context, params model.DeleteUserInput) (*model.Response, error)
UpdateUser(ctx context.Context, params model.UpdateUserInput) (*model.User, error)
AdminSignup(ctx context.Context, params model.AdminSignupInput) (*model.Response, error)
AdminLogin(ctx context.Context, params model.AdminLoginInput) (*model.Response, error)
2021-12-31 17:36:06 +00:00
AdminLogout(ctx context.Context) (*model.Response, error)
2022-01-17 07:42:46 +00:00
UpdateEnv(ctx context.Context, params model.UpdateEnvInput) (*model.Response, error)
}
type QueryResolver interface {
Meta(ctx context.Context) (*model.Meta, error)
Session(ctx context.Context, roles []string) (*model.AuthResponse, error)
Profile(ctx context.Context) (*model.User, error)
Users(ctx context.Context) ([]*model.User, error)
VerificationRequests(ctx context.Context) ([]*model.VerificationRequest, error)
AdminSession(ctx context.Context) (*model.Response, error)
2022-01-17 07:42:46 +00:00
Env(ctx context.Context) (*model.Env, error)
}
type executableSchema struct {
resolvers ResolverRoot
directives DirectiveRoot
complexity ComplexityRoot
}
func (e *executableSchema) Schema() *ast.Schema {
return parsedSchema
}
func (e *executableSchema) Complexity(typeName, field string, childComplexity int, rawArgs map[string]interface{}) (int, bool) {
ec := executionContext{nil, e}
_ = ec
switch typeName + "." + field {
case "AuthResponse.access_token":
if e.complexity.AuthResponse.AccessToken == nil {
2021-07-12 18:22:16 +00:00
break
}
return e.complexity.AuthResponse.AccessToken(childComplexity), true
2021-07-12 18:22:16 +00:00
case "AuthResponse.expires_at":
if e.complexity.AuthResponse.ExpiresAt == nil {
2021-07-12 18:22:16 +00:00
break
}
return e.complexity.AuthResponse.ExpiresAt(childComplexity), true
2021-07-12 18:22:16 +00:00
case "AuthResponse.message":
if e.complexity.AuthResponse.Message == nil {
2021-07-12 18:22:16 +00:00
break
}
return e.complexity.AuthResponse.Message(childComplexity), true
case "AuthResponse.user":
if e.complexity.AuthResponse.User == nil {
2021-07-15 12:02:55 +00:00
break
}
return e.complexity.AuthResponse.User(childComplexity), true
2021-07-15 12:02:55 +00:00
2022-01-17 07:42:46 +00:00
case "Env.ADMIN_SECRET":
if e.complexity.Env.AdminSecret == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.AdminSecret(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.ALLOWED_ORIGINS":
if e.complexity.Env.AllowedOrigins == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.AllowedOrigins(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.APP_URL":
if e.complexity.Env.AppURL == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.AppURL(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.AUTHORIZER_URL":
if e.complexity.Env.AuthorizerURL == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.AuthorizerURL(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.COOKIE_NAME":
if e.complexity.Env.CookieName == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.CookieName(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.DEFAULT_ROLES":
if e.complexity.Env.DefaultRoles == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.DefaultRoles(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.DISABLE_BASIC_AUTHENTICATION":
if e.complexity.Env.DisableBasicAuthentication == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.DisableBasicAuthentication(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.DISABLE_EMAIL_VERIFICATION":
if e.complexity.Env.DisableEmailVerification == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.DisableEmailVerification(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.DISABLE_LOGIN_PAGE":
if e.complexity.Env.DisableLoginPage == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.DisableLoginPage(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.DISABLE_MAGIC_LINK_LOGIN":
if e.complexity.Env.DisableMagicLinkLogin == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.DisableMagicLinkLogin(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.FACEBOOK_CLIENT_ID":
if e.complexity.Env.FacebookClientID == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.FacebookClientID(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.FACEBOOK_CLIENT_SECRET":
if e.complexity.Env.FacebookClientSecret == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.FacebookClientSecret(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.GITHUB_CLIENT_ID":
if e.complexity.Env.GithubClientID == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.GithubClientID(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.GITHUB_CLIENT_SECRET":
if e.complexity.Env.GithubClientSecret == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.GithubClientSecret(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.GOOGLE_CLIENT_ID":
if e.complexity.Env.GoogleClientID == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.GoogleClientID(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.GOOGLE_CLIENT_SECRET":
if e.complexity.Env.GoogleClientSecret == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.GoogleClientSecret(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.JWT_ROLE_CLAIM":
if e.complexity.Env.JwtRoleClaim == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.JwtRoleClaim(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.JWT_SECRET":
if e.complexity.Env.JwtSecret == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.JwtSecret(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.JWT_TYPE":
if e.complexity.Env.JwtType == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.JwtType(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.ORGANIZATION_LOGO":
if e.complexity.Env.OrganizationLogo == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.OrganizationLogo(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.ORGANIZATION_NAME":
if e.complexity.Env.OrganizationName == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.OrganizationName(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.PROTECTED_ROLES":
if e.complexity.Env.ProtectedRoles == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.ProtectedRoles(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.REDIS_URL":
if e.complexity.Env.RedisURL == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.RedisURL(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.RESET_PASSWORD_URL":
if e.complexity.Env.ResetPasswordURL == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.ResetPasswordURL(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.ROLES":
if e.complexity.Env.Roles == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.Roles(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.SMTP_HOST":
if e.complexity.Env.SMTPHost == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.SMTPHost(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.SMTP_PASSWORD":
if e.complexity.Env.SMTPPassword == nil {
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.SMTPPassword(childComplexity), true
2022-01-17 07:42:46 +00:00
case "Env.SMTP_PORT":
if e.complexity.Env.SMTPPort == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.SMTPPort(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.SMTP_USERNAME":
if e.complexity.Env.SMTPUsername == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.SMTPUsername(childComplexity), true
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
case "Env.SENDER_EMAIL":
if e.complexity.Env.SenderEmail == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Env.SenderEmail(childComplexity), true
2021-12-31 11:33:37 +00:00
case "Error.message":
if e.complexity.Error.Message == nil {
break
}
return e.complexity.Error.Message(childComplexity), true
case "Error.reason":
if e.complexity.Error.Reason == nil {
break
2021-07-12 18:22:16 +00:00
}
return e.complexity.Error.Reason(childComplexity), true
2021-07-12 18:22:16 +00:00
case "Meta.is_basic_authentication_enabled":
if e.complexity.Meta.IsBasicAuthenticationEnabled == nil {
break
}
return e.complexity.Meta.IsBasicAuthenticationEnabled(childComplexity), true
case "Meta.is_email_verification_enabled":
if e.complexity.Meta.IsEmailVerificationEnabled == nil {
break
}
return e.complexity.Meta.IsEmailVerificationEnabled(childComplexity), true
case "Meta.is_facebook_login_enabled":
if e.complexity.Meta.IsFacebookLoginEnabled == nil {
break
}
return e.complexity.Meta.IsFacebookLoginEnabled(childComplexity), true
case "Meta.is_github_login_enabled":
if e.complexity.Meta.IsGithubLoginEnabled == nil {
break
}
return e.complexity.Meta.IsGithubLoginEnabled(childComplexity), true
case "Meta.is_google_login_enabled":
if e.complexity.Meta.IsGoogleLoginEnabled == nil {
break
}
return e.complexity.Meta.IsGoogleLoginEnabled(childComplexity), true
case "Meta.is_magic_link_login_enabled":
if e.complexity.Meta.IsMagicLinkLoginEnabled == nil {
break
}
return e.complexity.Meta.IsMagicLinkLoginEnabled(childComplexity), true
case "Meta.version":
if e.complexity.Meta.Version == nil {
break
}
return e.complexity.Meta.Version(childComplexity), true
2021-12-30 04:31:51 +00:00
case "Mutation._admin_login":
if e.complexity.Mutation.AdminLogin == nil {
break
}
args, err := ec.field_Mutation__admin_login_args(context.TODO(), rawArgs)
if err != nil {
return 0, false
}
return e.complexity.Mutation.AdminLogin(childComplexity, args["params"].(model.AdminLoginInput)), true
2021-12-31 17:36:06 +00:00
case "Mutation._admin_logout":
if e.complexity.Mutation.AdminLogout == nil {
break
}
return e.complexity.Mutation.AdminLogout(childComplexity), true
2022-01-09 12:05:37 +00:00
case "Mutation._admin_signup":
if e.complexity.Mutation.AdminSignup == nil {
break
}
args, err := ec.field_Mutation__admin_signup_args(context.TODO(), rawArgs)
if err != nil {
return 0, false
}
return e.complexity.Mutation.AdminSignup(childComplexity, args["params"].(model.AdminSignupInput)), true
2022-01-09 12:05:37 +00:00
case "Mutation._delete_user":
2021-08-06 13:47:52 +00:00
if e.complexity.Mutation.DeleteUser == nil {
break
}
args, err := ec.field_Mutation__delete_user_args(context.TODO(), rawArgs)
2021-08-06 13:47:52 +00:00
if err != nil {
return 0, false
}
return e.complexity.Mutation.DeleteUser(childComplexity, args["params"].(model.DeleteUserInput)), true
case "Mutation.forgot_password":
if e.complexity.Mutation.ForgotPassword == nil {
break
}
args, err := ec.field_Mutation_forgot_password_args(context.TODO(), rawArgs)
if err != nil {
return 0, false
}
return e.complexity.Mutation.ForgotPassword(childComplexity, args["params"].(model.ForgotPasswordInput)), true
2021-07-15 09:43:00 +00:00
case "Mutation.login":
if e.complexity.Mutation.Login == nil {
break
}
2021-07-15 09:43:00 +00:00
args, err := ec.field_Mutation_login_args(context.TODO(), rawArgs)
if err != nil {
return 0, false
}
2021-07-15 09:43:00 +00:00
return e.complexity.Mutation.Login(childComplexity, args["params"].(model.LoginInput)), true
2021-07-15 09:43:00 +00:00
case "Mutation.logout":
if e.complexity.Mutation.Logout == nil {
break
}
2021-07-15 09:43:00 +00:00
return e.complexity.Mutation.Logout(childComplexity), true
case "Mutation.magic_link_login":
if e.complexity.Mutation.MagicLinkLogin == nil {
break
}
args, err := ec.field_Mutation_magic_link_login_args(context.TODO(), rawArgs)
if err != nil {
return 0, false
}
return e.complexity.Mutation.MagicLinkLogin(childComplexity, args["params"].(model.MagicLinkLoginInput)), true
case "Mutation.resend_verify_email":
if e.complexity.Mutation.ResendVerifyEmail == nil {
break
}
args, err := ec.field_Mutation_resend_verify_email_args(context.TODO(), rawArgs)
if err != nil {
return 0, false
}
return e.complexity.Mutation.ResendVerifyEmail(childComplexity, args["params"].(model.ResendVerifyEmailInput)), true
case "Mutation.reset_password":
if e.complexity.Mutation.ResetPassword == nil {
break
}
args, err := ec.field_Mutation_reset_password_args(context.TODO(), rawArgs)
if err != nil {
return 0, false
}
2021-08-07 08:41:26 +00:00
return e.complexity.Mutation.ResetPassword(childComplexity, args["params"].(model.ResetPasswordInput)), true
2021-07-15 09:43:00 +00:00
case "Mutation.signup":
if e.complexity.Mutation.Signup == nil {
break
}
args, err := ec.field_Mutation_signup_args(context.TODO(), rawArgs)
if err != nil {
return 0, false
}
2021-07-15 09:43:00 +00:00
return e.complexity.Mutation.Signup(childComplexity, args["params"].(model.SignUpInput)), true
2022-01-17 07:42:46 +00:00
case "Mutation._update_env":
if e.complexity.Mutation.UpdateEnv == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
args, err := ec.field_Mutation__update_env_args(context.TODO(), rawArgs)
2021-12-31 11:33:37 +00:00
if err != nil {
return 0, false
}
2022-01-17 07:42:46 +00:00
return e.complexity.Mutation.UpdateEnv(childComplexity, args["params"].(model.UpdateEnvInput)), true
2021-12-31 11:33:37 +00:00
case "Mutation.update_profile":
if e.complexity.Mutation.UpdateProfile == nil {
break
}
args, err := ec.field_Mutation_update_profile_args(context.TODO(), rawArgs)
if err != nil {
return 0, false
}
return e.complexity.Mutation.UpdateProfile(childComplexity, args["params"].(model.UpdateProfileInput)), true
case "Mutation._update_user":
if e.complexity.Mutation.UpdateUser == nil {
break
}
args, err := ec.field_Mutation__update_user_args(context.TODO(), rawArgs)
if err != nil {
return 0, false
}
return e.complexity.Mutation.UpdateUser(childComplexity, args["params"].(model.UpdateUserInput)), true
case "Mutation.verify_email":
if e.complexity.Mutation.VerifyEmail == nil {
break
}
args, err := ec.field_Mutation_verify_email_args(context.TODO(), rawArgs)
if err != nil {
return 0, false
}
return e.complexity.Mutation.VerifyEmail(childComplexity, args["params"].(model.VerifyEmailInput)), true
2021-12-30 04:31:51 +00:00
case "Query._admin_session":
if e.complexity.Query.AdminSession == nil {
break
}
return e.complexity.Query.AdminSession(childComplexity), true
2022-01-17 07:42:46 +00:00
case "Query._env":
if e.complexity.Query.Env == nil {
2021-12-31 11:33:37 +00:00
break
}
2022-01-17 07:42:46 +00:00
return e.complexity.Query.Env(childComplexity), true
2021-12-31 11:33:37 +00:00
case "Query.meta":
if e.complexity.Query.Meta == nil {
break
}
return e.complexity.Query.Meta(childComplexity), true
case "Query.profile":
if e.complexity.Query.Profile == nil {
break
}
return e.complexity.Query.Profile(childComplexity), true
case "Query.session":
if e.complexity.Query.Session == nil {
break
}
args, err := ec.field_Query_session_args(context.TODO(), rawArgs)
if err != nil {
return 0, false
}
return e.complexity.Query.Session(childComplexity, args["roles"].([]string)), true
case "Query._users":
if e.complexity.Query.Users == nil {
break
}
return e.complexity.Query.Users(childComplexity), true
case "Query._verification_requests":
if e.complexity.Query.VerificationRequests == nil {
break
}
return e.complexity.Query.VerificationRequests(childComplexity), true
2021-07-15 09:43:00 +00:00
case "Response.message":
if e.complexity.Response.Message == nil {
break
}
return e.complexity.Response.Message(childComplexity), true
case "User.birthdate":
if e.complexity.User.Birthdate == nil {
break
}
return e.complexity.User.Birthdate(childComplexity), true
case "User.created_at":
2021-07-12 18:22:16 +00:00
if e.complexity.User.CreatedAt == nil {
break
}
2021-07-12 18:22:16 +00:00
return e.complexity.User.CreatedAt(childComplexity), true
2021-07-12 18:22:16 +00:00
case "User.email":
if e.complexity.User.Email == nil {
break
}
2021-07-12 18:22:16 +00:00
return e.complexity.User.Email(childComplexity), true
case "User.email_verified":
if e.complexity.User.EmailVerified == nil {
break
}
return e.complexity.User.EmailVerified(childComplexity), true
case "User.family_name":
if e.complexity.User.FamilyName == nil {
break
}
return e.complexity.User.FamilyName(childComplexity), true
case "User.gender":
if e.complexity.User.Gender == nil {
break
}
return e.complexity.User.Gender(childComplexity), true
case "User.given_name":
if e.complexity.User.GivenName == nil {
break
}
return e.complexity.User.GivenName(childComplexity), true
case "User.id":
if e.complexity.User.ID == nil {
break
}
return e.complexity.User.ID(childComplexity), true
case "User.middle_name":
if e.complexity.User.MiddleName == nil {
break
}
return e.complexity.User.MiddleName(childComplexity), true
case "User.nickname":
if e.complexity.User.Nickname == nil {
break
}
return e.complexity.User.Nickname(childComplexity), true
case "User.phone_number":
if e.complexity.User.PhoneNumber == nil {
break
}
return e.complexity.User.PhoneNumber(childComplexity), true
case "User.phone_number_verified":
if e.complexity.User.PhoneNumberVerified == nil {
break
}
return e.complexity.User.PhoneNumberVerified(childComplexity), true
case "User.picture":
if e.complexity.User.Picture == nil {
2021-07-12 18:22:16 +00:00
break
}
return e.complexity.User.Picture(childComplexity), true
2021-07-12 18:22:16 +00:00
case "User.preferred_username":
if e.complexity.User.PreferredUsername == nil {
2021-07-12 18:22:16 +00:00
break
}
return e.complexity.User.PreferredUsername(childComplexity), true
2021-07-12 18:22:16 +00:00
case "User.roles":
if e.complexity.User.Roles == nil {
break
}
return e.complexity.User.Roles(childComplexity), true
case "User.signup_methods":
if e.complexity.User.SignupMethods == nil {
2021-07-12 18:22:16 +00:00
break
}
return e.complexity.User.SignupMethods(childComplexity), true
2021-07-12 18:22:16 +00:00
case "User.updated_at":
2021-07-12 18:22:16 +00:00
if e.complexity.User.UpdatedAt == nil {
break
}
return e.complexity.User.UpdatedAt(childComplexity), true
case "VerificationRequest.created_at":
2021-07-12 18:22:16 +00:00
if e.complexity.VerificationRequest.CreatedAt == nil {
break
}
return e.complexity.VerificationRequest.CreatedAt(childComplexity), true
case "VerificationRequest.email":
if e.complexity.VerificationRequest.Email == nil {
break
}
return e.complexity.VerificationRequest.Email(childComplexity), true
case "VerificationRequest.expires":
if e.complexity.VerificationRequest.Expires == nil {
break
}
2021-07-12 18:22:16 +00:00
return e.complexity.VerificationRequest.Expires(childComplexity), true
case "VerificationRequest.id":
if e.complexity.VerificationRequest.ID == nil {
break
}
return e.complexity.VerificationRequest.ID(childComplexity), true
case "VerificationRequest.identifier":
if e.complexity.VerificationRequest.Identifier == nil {
break
}
return e.complexity.VerificationRequest.Identifier(childComplexity), true
case "VerificationRequest.token":
if e.complexity.VerificationRequest.Token == nil {
break
}
return e.complexity.VerificationRequest.Token(childComplexity), true
case "VerificationRequest.updated_at":
2021-07-12 18:22:16 +00:00
if e.complexity.VerificationRequest.UpdatedAt == nil {
break
}
return e.complexity.VerificationRequest.UpdatedAt(childComplexity), true
}
return 0, false
}
func (e *executableSchema) Exec(ctx context.Context) graphql.ResponseHandler {
rc := graphql.GetOperationContext(ctx)
ec := executionContext{rc, e}
first := true
switch rc.Operation.Operation {
case ast.Query:
return func(ctx context.Context) *graphql.Response {
if !first {
return nil
}
first = false
data := ec._Query(ctx, rc.Operation.SelectionSet)
var buf bytes.Buffer
data.MarshalGQL(&buf)
return &graphql.Response{
Data: buf.Bytes(),
}
}
case ast.Mutation:
return func(ctx context.Context) *graphql.Response {
if !first {
return nil
}
first = false
data := ec._Mutation(ctx, rc.Operation.SelectionSet)
var buf bytes.Buffer
data.MarshalGQL(&buf)
return &graphql.Response{
Data: buf.Bytes(),
}
}
default:
return graphql.OneShot(graphql.ErrorResponse(ctx, "unsupported GraphQL operation"))
}
}
type executionContext struct {
*graphql.OperationContext
*executableSchema
}
func (ec *executionContext) introspectSchema() (*introspection.Schema, error) {
if ec.DisableIntrospection {
return nil, errors.New("introspection disabled")
}
return introspection.WrapSchema(parsedSchema), nil
}
func (ec *executionContext) introspectType(name string) (*introspection.Type, error) {
if ec.DisableIntrospection {
return nil, errors.New("introspection disabled")
}
return introspection.WrapTypeFromDef(parsedSchema, parsedSchema.Types[name]), nil
}
var sources = []*ast.Source{
{Name: "graph/schema.graphqls", Input: `# GraphQL schema example
#
# https://gqlgen.com/getting-started/
2021-07-12 18:22:16 +00:00
scalar Int64
scalar Map
scalar Any
type Meta {
2021-08-06 13:47:52 +00:00
version: String!
is_google_login_enabled: Boolean!
is_facebook_login_enabled: Boolean!
is_github_login_enabled: Boolean!
is_email_verification_enabled: Boolean!
is_basic_authentication_enabled: Boolean!
is_magic_link_login_enabled: Boolean!
}
2021-07-12 18:22:16 +00:00
type User {
2021-08-06 13:47:52 +00:00
id: ID!
email: String!
email_verified: Boolean!
signup_methods: String!
given_name: String
family_name: String
middle_name: String
nickname: String
# defaults to email
preferred_username: String
gender: String
birthdate: String
phone_number: String
phone_number_verified: Boolean
picture: String
roles: [String!]!
created_at: Int64
updated_at: Int64
2021-07-12 18:22:16 +00:00
}
type VerificationRequest {
2021-08-06 13:47:52 +00:00
id: ID!
identifier: String
token: String
email: String
expires: Int64
created_at: Int64
updated_at: Int64
}
2021-07-12 18:22:16 +00:00
type Error {
2021-08-06 13:47:52 +00:00
message: String!
reason: String!
2021-07-12 18:22:16 +00:00
}
type AuthResponse {
2021-08-06 13:47:52 +00:00
message: String!
access_token: String
expires_at: Int64
2021-08-06 13:47:52 +00:00
user: User
2021-07-12 18:22:16 +00:00
}
2021-07-15 09:43:00 +00:00
type Response {
2021-08-06 13:47:52 +00:00
message: String!
2021-07-15 09:43:00 +00:00
}
2022-01-17 07:42:46 +00:00
type Env {
2021-12-31 11:33:37 +00:00
ADMIN_SECRET: String
SMTP_HOST: String
SMTP_PORT: String
SMTP_USERNAME: String
SMTP_PASSWORD: String
2021-12-31 11:33:37 +00:00
SENDER_EMAIL: String
JWT_TYPE: String
JWT_SECRET: String
ALLOWED_ORIGINS: [String!]
AUTHORIZER_URL: String
APP_URL: String
REDIS_URL: String
COOKIE_NAME: String
RESET_PASSWORD_URL: String
DISABLE_EMAIL_VERIFICATION: Boolean
DISABLE_BASIC_AUTHENTICATION: Boolean
DISABLE_MAGIC_LINK_LOGIN: Boolean
DISABLE_LOGIN_PAGE: Boolean
ROLES: [String!]
PROTECTED_ROLES: [String!]
DEFAULT_ROLES: [String!]
JWT_ROLE_CLAIM: String
GOOGLE_CLIENT_ID: String
GOOGLE_CLIENT_SECRET: String
GITHUB_CLIENT_ID: String
GITHUB_CLIENT_SECRET: String
FACEBOOK_CLIENT_ID: String
FACEBOOK_CLIENT_SECRET: String
ORGANIZATION_NAME: String
ORGANIZATION_LOGO: String
}
2022-01-17 07:42:46 +00:00
input UpdateEnvInput {
2021-12-31 11:33:37 +00:00
ADMIN_SECRET: String
OLD_ADMIN_SECRET: String
2021-12-31 11:33:37 +00:00
SMTP_HOST: String
SMTP_PORT: String
SENDER_EMAIL: String
SENDER_PASSWORD: String
JWT_TYPE: String
JWT_SECRET: String
ALLOWED_ORIGINS: [String!]
AUTHORIZER_URL: String
APP_URL: String
REDIS_URL: String
COOKIE_NAME: String
RESET_PASSWORD_URL: String
DISABLE_EMAIL_VERIFICATION: Boolean
DISABLE_BASIC_AUTHENTICATION: Boolean
DISABLE_MAGIC_LINK_LOGIN: Boolean
DISABLE_LOGIN_PAGE: Boolean
ROLES: [String!]
PROTECTED_ROLES: [String!]
DEFAULT_ROLES: [String!]
JWT_ROLE_CLAIM: String
GOOGLE_CLIENT_ID: String
GOOGLE_CLIENT_SECRET: String
GITHUB_CLIENT_ID: String
GITHUB_CLIENT_SECRET: String
FACEBOOK_CLIENT_ID: String
FACEBOOK_CLIENT_SECRET: String
ORGANIZATION_NAME: String
ORGANIZATION_LOGO: String
}
2021-12-30 04:31:51 +00:00
input AdminLoginInput {
admin_secret: String!
}
input AdminSignupInput {
admin_secret: String!
}
2021-07-15 09:43:00 +00:00
input SignUpInput {
2021-08-06 13:47:52 +00:00
email: String!
given_name: String
family_name: String
middle_name: String
nickname: String
gender: String
birthdate: String
phone_number: String
picture: String
2021-08-06 13:47:52 +00:00
password: String!
confirm_password: String!
roles: [String!]
}
input LoginInput {
2021-08-06 13:47:52 +00:00
email: String!
password: String!
roles: [String!]
}
input VerifyEmailInput {
2021-08-06 13:47:52 +00:00
token: String!
}
input ResendVerifyEmailInput {
2021-08-06 13:47:52 +00:00
email: String!
identifier: String!
}
input UpdateProfileInput {
old_password: String
new_password: String
confirm_new_password: String
2021-08-06 13:47:52 +00:00
email: String
given_name: String
family_name: String
middle_name: String
nickname: String
gender: String
birthdate: String
phone_number: String
picture: String
}
input UpdateUserInput {
id: ID!
email: String
2022-01-17 06:02:13 +00:00
email_verified: Boolean
given_name: String
family_name: String
middle_name: String
nickname: String
gender: String
birthdate: String
phone_number: String
picture: String
roles: [String]
}
input ForgotPasswordInput {
2021-08-06 13:47:52 +00:00
email: String!
}
2021-08-07 08:41:26 +00:00
input ResetPasswordInput {
2021-08-06 13:47:52 +00:00
token: String!
password: String!
confirm_password: String!
2021-08-06 13:47:52 +00:00
}
input DeleteUserInput {
email: String!
}
input MagicLinkLoginInput {
email: String!
roles: [String!]
}
type Mutation {
2021-08-06 13:47:52 +00:00
signup(params: SignUpInput!): AuthResponse!
login(params: LoginInput!): AuthResponse!
magic_link_login(params: MagicLinkLoginInput!): Response!
2021-08-06 13:47:52 +00:00
logout: Response!
update_profile(params: UpdateProfileInput!): Response!
verify_email(params: VerifyEmailInput!): AuthResponse!
resend_verify_email(params: ResendVerifyEmailInput!): Response!
forgot_password(params: ForgotPasswordInput!): Response!
reset_password(params: ResetPasswordInput!): Response!
# admin only apis
_delete_user(params: DeleteUserInput!): Response!
_update_user(params: UpdateUserInput!): User!
_admin_signup(params: AdminSignupInput!): Response!
_admin_login(params: AdminLoginInput!): Response!
2021-12-31 17:36:06 +00:00
_admin_logout: Response!
2022-01-17 07:42:46 +00:00
_update_env(params: UpdateEnvInput!): Response!
}
type Query {
2021-08-06 13:47:52 +00:00
meta: Meta!
2021-12-31 11:33:37 +00:00
session(roles: [String!]): AuthResponse!
2021-08-06 13:47:52 +00:00
profile: User!
# admin only apis
_users: [User!]!
_verification_requests: [VerificationRequest!]!
_admin_session: Response!
2022-01-17 07:42:46 +00:00
_env: Env!
2021-07-12 18:22:16 +00:00
}
`, BuiltIn: false},
}
var parsedSchema = gqlparser.MustLoadSchema(sources...)
// endregion ************************** generated!.gotpl **************************
// region ***************************** args.gotpl *****************************
2021-12-30 04:31:51 +00:00
func (ec *executionContext) field_Mutation__admin_login_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) {
var err error
args := map[string]interface{}{}
var arg0 model.AdminLoginInput
if tmp, ok := rawArgs["params"]; ok {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("params"))
arg0, err = ec.unmarshalNAdminLoginInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐAdminLoginInput(ctx, tmp)
if err != nil {
return nil, err
}
}
args["params"] = arg0
return args, nil
}
2022-01-09 12:05:37 +00:00
func (ec *executionContext) field_Mutation__admin_signup_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) {
var err error
args := map[string]interface{}{}
var arg0 model.AdminSignupInput
2022-01-09 12:05:37 +00:00
if tmp, ok := rawArgs["params"]; ok {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("params"))
arg0, err = ec.unmarshalNAdminSignupInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐAdminSignupInput(ctx, tmp)
2022-01-09 12:05:37 +00:00
if err != nil {
return nil, err
}
}
args["params"] = arg0
return args, nil
}
func (ec *executionContext) field_Mutation__delete_user_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) {
var err error
args := map[string]interface{}{}
var arg0 model.DeleteUserInput
if tmp, ok := rawArgs["params"]; ok {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("params"))
arg0, err = ec.unmarshalNDeleteUserInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐDeleteUserInput(ctx, tmp)
if err != nil {
return nil, err
}
}
args["params"] = arg0
return args, nil
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) field_Mutation__update_env_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) {
2021-12-31 11:33:37 +00:00
var err error
args := map[string]interface{}{}
2022-01-17 07:42:46 +00:00
var arg0 model.UpdateEnvInput
2021-12-31 11:33:37 +00:00
if tmp, ok := rawArgs["params"]; ok {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("params"))
2022-01-17 07:42:46 +00:00
arg0, err = ec.unmarshalNUpdateEnvInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐUpdateEnvInput(ctx, tmp)
2021-12-31 11:33:37 +00:00
if err != nil {
return nil, err
}
}
args["params"] = arg0
return args, nil
}
func (ec *executionContext) field_Mutation__update_user_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) {
2021-08-06 13:47:52 +00:00
var err error
args := map[string]interface{}{}
var arg0 model.UpdateUserInput
2021-08-06 13:47:52 +00:00
if tmp, ok := rawArgs["params"]; ok {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("params"))
arg0, err = ec.unmarshalNUpdateUserInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐUpdateUserInput(ctx, tmp)
2021-08-06 13:47:52 +00:00
if err != nil {
return nil, err
}
}
args["params"] = arg0
return args, nil
}
func (ec *executionContext) field_Mutation_forgot_password_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) {
var err error
args := map[string]interface{}{}
var arg0 model.ForgotPasswordInput
if tmp, ok := rawArgs["params"]; ok {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("params"))
2021-07-28 06:23:37 +00:00
arg0, err = ec.unmarshalNForgotPasswordInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐForgotPasswordInput(ctx, tmp)
if err != nil {
return nil, err
}
}
args["params"] = arg0
return args, nil
}
func (ec *executionContext) field_Mutation_login_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) {
var err error
args := map[string]interface{}{}
var arg0 model.LoginInput
if tmp, ok := rawArgs["params"]; ok {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("params"))
2021-07-28 06:23:37 +00:00
arg0, err = ec.unmarshalNLoginInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐLoginInput(ctx, tmp)
if err != nil {
return nil, err
}
}
args["params"] = arg0
return args, nil
}
func (ec *executionContext) field_Mutation_magic_link_login_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) {
var err error
args := map[string]interface{}{}
var arg0 model.MagicLinkLoginInput
if tmp, ok := rawArgs["params"]; ok {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("params"))
arg0, err = ec.unmarshalNMagicLinkLoginInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐMagicLinkLoginInput(ctx, tmp)
if err != nil {
return nil, err
}
}
args["params"] = arg0
return args, nil
}
func (ec *executionContext) field_Mutation_resend_verify_email_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) {
2021-07-12 18:22:16 +00:00
var err error
args := map[string]interface{}{}
var arg0 model.ResendVerifyEmailInput
2021-07-12 18:22:16 +00:00
if tmp, ok := rawArgs["params"]; ok {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("params"))
2021-07-28 06:23:37 +00:00
arg0, err = ec.unmarshalNResendVerifyEmailInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐResendVerifyEmailInput(ctx, tmp)
2021-07-12 18:22:16 +00:00
if err != nil {
return nil, err
}
}
args["params"] = arg0
return args, nil
}
func (ec *executionContext) field_Mutation_reset_password_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) {
var err error
args := map[string]interface{}{}
2021-08-07 08:41:26 +00:00
var arg0 model.ResetPasswordInput
if tmp, ok := rawArgs["params"]; ok {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("params"))
2021-08-07 08:41:26 +00:00
arg0, err = ec.unmarshalNResetPasswordInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐResetPasswordInput(ctx, tmp)
if err != nil {
return nil, err
}
}
args["params"] = arg0
return args, nil
}
2021-07-15 09:43:00 +00:00
func (ec *executionContext) field_Mutation_signup_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) {
var err error
args := map[string]interface{}{}
2021-07-15 09:43:00 +00:00
var arg0 model.SignUpInput
2021-07-12 18:22:16 +00:00
if tmp, ok := rawArgs["params"]; ok {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("params"))
2021-07-28 06:23:37 +00:00
arg0, err = ec.unmarshalNSignUpInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐSignUpInput(ctx, tmp)
if err != nil {
return nil, err
}
}
2021-07-12 18:22:16 +00:00
args["params"] = arg0
return args, nil
}
func (ec *executionContext) field_Mutation_update_profile_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) {
var err error
args := map[string]interface{}{}
var arg0 model.UpdateProfileInput
if tmp, ok := rawArgs["params"]; ok {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("params"))
2021-07-28 06:23:37 +00:00
arg0, err = ec.unmarshalNUpdateProfileInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐUpdateProfileInput(ctx, tmp)
if err != nil {
return nil, err
}
}
args["params"] = arg0
return args, nil
}
func (ec *executionContext) field_Mutation_verify_email_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) {
var err error
args := map[string]interface{}{}
var arg0 model.VerifyEmailInput
if tmp, ok := rawArgs["params"]; ok {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("params"))
2021-07-28 06:23:37 +00:00
arg0, err = ec.unmarshalNVerifyEmailInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐVerifyEmailInput(ctx, tmp)
if err != nil {
return nil, err
}
}
args["params"] = arg0
return args, nil
}
func (ec *executionContext) field_Query___type_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) {
var err error
args := map[string]interface{}{}
var arg0 string
if tmp, ok := rawArgs["name"]; ok {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("name"))
arg0, err = ec.unmarshalNString2string(ctx, tmp)
if err != nil {
return nil, err
}
}
args["name"] = arg0
return args, nil
}
func (ec *executionContext) field_Query_session_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) {
var err error
args := map[string]interface{}{}
var arg0 []string
if tmp, ok := rawArgs["roles"]; ok {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("roles"))
arg0, err = ec.unmarshalOString2ᚕstringᚄ(ctx, tmp)
if err != nil {
return nil, err
}
}
args["roles"] = arg0
return args, nil
}
func (ec *executionContext) field___Type_enumValues_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) {
var err error
args := map[string]interface{}{}
var arg0 bool
if tmp, ok := rawArgs["includeDeprecated"]; ok {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("includeDeprecated"))
arg0, err = ec.unmarshalOBoolean2bool(ctx, tmp)
if err != nil {
return nil, err
}
}
args["includeDeprecated"] = arg0
return args, nil
}
func (ec *executionContext) field___Type_fields_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) {
var err error
args := map[string]interface{}{}
var arg0 bool
if tmp, ok := rawArgs["includeDeprecated"]; ok {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("includeDeprecated"))
arg0, err = ec.unmarshalOBoolean2bool(ctx, tmp)
if err != nil {
return nil, err
}
}
args["includeDeprecated"] = arg0
return args, nil
}
// endregion ***************************** args.gotpl *****************************
// region ************************** directives.gotpl **************************
// endregion ************************** directives.gotpl **************************
// region **************************** field.gotpl *****************************
func (ec *executionContext) _AuthResponse_message(ctx context.Context, field graphql.CollectedField, obj *model.AuthResponse) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "AuthResponse",
Field: field,
Args: nil,
2021-07-12 18:22:16 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
2021-07-12 18:22:16 +00:00
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Message, nil
2021-07-12 18:22:16 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
2021-07-12 18:22:16 +00:00
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) _AuthResponse_access_token(ctx context.Context, field graphql.CollectedField, obj *model.AuthResponse) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "AuthResponse",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.AccessToken, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
res := resTmp.(*string)
fc.Result = res
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) _AuthResponse_expires_at(ctx context.Context, field graphql.CollectedField, obj *model.AuthResponse) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "AuthResponse",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.ExpiresAt, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
res := resTmp.(*int64)
fc.Result = res
return ec.marshalOInt642ᚖint64(ctx, field.Selections, res)
}
func (ec *executionContext) _AuthResponse_user(ctx context.Context, field graphql.CollectedField, obj *model.AuthResponse) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "AuthResponse",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.User, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
res := resTmp.(*model.User)
fc.Result = res
return ec.marshalOUser2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐUser(ctx, field.Selections, res)
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_ADMIN_SECRET(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
2021-07-15 12:02:55 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
2021-07-15 12:02:55 +00:00
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.AdminSecret, nil
2021-07-15 12:02:55 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
2021-07-15 12:02:55 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
2021-07-15 12:02:55 +00:00
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_SMTP_HOST(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.SMTPHost, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_SMTP_PORT(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.SMTPPort, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_SMTP_USERNAME(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.SMTPUsername, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
res := resTmp.(*string)
fc.Result = res
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_SMTP_PASSWORD(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.SMTPPassword, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_SENDER_EMAIL(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.SenderEmail, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_JWT_TYPE(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.JwtType, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_JWT_SECRET(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
2021-07-12 18:22:16 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
2021-07-12 18:22:16 +00:00
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
2021-07-12 18:22:16 +00:00
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.JwtSecret, nil
2021-07-12 18:22:16 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
2021-07-12 18:22:16 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
2021-07-12 18:22:16 +00:00
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_ALLOWED_ORIGINS(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.AllowedOrigins, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.([]string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚕstringᚄ(ctx, field.Selections, res)
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_AUTHORIZER_URL(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.AuthorizerURL, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_APP_URL(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
2021-07-12 18:22:16 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
2021-07-12 18:22:16 +00:00
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
2021-07-12 18:22:16 +00:00
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.AppURL, nil
2021-07-12 18:22:16 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
2021-07-12 18:22:16 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
2021-07-12 18:22:16 +00:00
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_REDIS_URL(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.RedisURL, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_COOKIE_NAME(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
2021-07-15 09:43:00 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
2021-07-15 09:43:00 +00:00
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
2021-07-15 09:43:00 +00:00
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.CookieName, nil
2021-07-15 09:43:00 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
2021-07-15 09:43:00 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
2021-07-15 09:43:00 +00:00
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_RESET_PASSWORD_URL(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.ResetPasswordURL, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_DISABLE_EMAIL_VERIFICATION(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.DisableEmailVerification, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*bool)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOBoolean2ᚖbool(ctx, field.Selections, res)
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_DISABLE_BASIC_AUTHENTICATION(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.DisableBasicAuthentication, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*bool)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOBoolean2ᚖbool(ctx, field.Selections, res)
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_DISABLE_MAGIC_LINK_LOGIN(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
2021-08-06 13:47:52 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
2021-08-06 13:47:52 +00:00
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
2021-08-06 13:47:52 +00:00
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.DisableMagicLinkLogin, nil
2021-08-06 13:47:52 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*bool)
2021-08-06 13:47:52 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOBoolean2ᚖbool(ctx, field.Selections, res)
2021-08-06 13:47:52 +00:00
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_DISABLE_LOGIN_PAGE(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
2021-12-30 04:31:51 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
2021-12-30 04:31:51 +00:00
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
2021-12-30 04:31:51 +00:00
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.DisableLoginPage, nil
2021-12-30 04:31:51 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*bool)
2021-12-30 04:31:51 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOBoolean2ᚖbool(ctx, field.Selections, res)
2021-12-30 04:31:51 +00:00
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_ROLES(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.Roles, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.([]string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚕstringᚄ(ctx, field.Selections, res)
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_PROTECTED_ROLES(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
2021-07-12 18:22:16 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
2021-07-12 18:22:16 +00:00
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
2021-07-12 18:22:16 +00:00
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.ProtectedRoles, nil
2021-07-12 18:22:16 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.([]string)
2021-07-12 18:22:16 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚕstringᚄ(ctx, field.Selections, res)
2021-07-12 18:22:16 +00:00
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_DEFAULT_ROLES(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.DefaultRoles, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.([]string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚕstringᚄ(ctx, field.Selections, res)
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_JWT_ROLE_CLAIM(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.JwtRoleClaim, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_GOOGLE_CLIENT_ID(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.GoogleClientID, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_GOOGLE_CLIENT_SECRET(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
2021-12-30 04:31:51 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
2021-12-30 04:31:51 +00:00
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
2021-12-30 04:31:51 +00:00
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.GoogleClientSecret, nil
2021-12-30 04:31:51 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
2021-12-30 04:31:51 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
2021-12-30 04:31:51 +00:00
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_GITHUB_CLIENT_ID(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.GithubClientID, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_GITHUB_CLIENT_SECRET(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.GithubClientSecret, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_FACEBOOK_CLIENT_ID(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
2021-07-15 09:43:00 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
2021-07-15 09:43:00 +00:00
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.FacebookClientID, nil
2021-07-15 09:43:00 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
2021-07-15 09:43:00 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
2021-07-15 09:43:00 +00:00
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_FACEBOOK_CLIENT_SECRET(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
2021-07-12 18:22:16 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
2021-07-12 18:22:16 +00:00
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.FacebookClientSecret, nil
2021-07-12 18:22:16 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
2021-07-12 18:22:16 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
2021-07-12 18:22:16 +00:00
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_ORGANIZATION_NAME(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
2021-07-12 18:22:16 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
2021-07-12 18:22:16 +00:00
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.OrganizationName, nil
2021-07-12 18:22:16 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
2021-07-12 18:22:16 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
2021-07-12 18:22:16 +00:00
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env_ORGANIZATION_LOGO(ctx context.Context, field graphql.CollectedField, obj *model.Env) (ret graphql.Marshaler) {
2021-07-12 18:22:16 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2022-01-17 07:42:46 +00:00
Object: "Env",
2021-07-12 18:22:16 +00:00
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.OrganizationLogo, nil
2021-07-12 18:22:16 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
2021-07-12 18:22:16 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
2021-07-12 18:22:16 +00:00
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Error_message(ctx context.Context, field graphql.CollectedField, obj *model.Error) (ret graphql.Marshaler) {
2021-07-12 18:22:16 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Error",
2021-07-12 18:22:16 +00:00
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.Message, nil
2021-07-12 18:22:16 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
2021-07-12 18:22:16 +00:00
return graphql.Null
}
res := resTmp.(string)
2021-07-12 18:22:16 +00:00
fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
2021-07-12 18:22:16 +00:00
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Error_reason(ctx context.Context, field graphql.CollectedField, obj *model.Error) (ret graphql.Marshaler) {
2021-07-12 18:22:16 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Error",
2021-07-12 18:22:16 +00:00
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.Reason, nil
2021-07-12 18:22:16 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
2021-07-12 18:22:16 +00:00
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(string)
2021-07-12 18:22:16 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNString2string(ctx, field.Selections, res)
2021-07-12 18:22:16 +00:00
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Meta_version(ctx context.Context, field graphql.CollectedField, obj *model.Meta) (ret graphql.Marshaler) {
2021-07-12 18:22:16 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Meta",
2021-07-12 18:22:16 +00:00
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.Version, nil
2021-07-12 18:22:16 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
2021-07-12 18:22:16 +00:00
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(string)
2021-07-12 18:22:16 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNString2string(ctx, field.Selections, res)
2021-07-12 18:22:16 +00:00
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Meta_is_google_login_enabled(ctx context.Context, field graphql.CollectedField, obj *model.Meta) (ret graphql.Marshaler) {
2021-07-12 18:22:16 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Meta",
2021-07-12 18:22:16 +00:00
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.IsGoogleLoginEnabled, nil
2021-07-12 18:22:16 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
2021-07-12 18:22:16 +00:00
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(bool)
2021-07-12 18:22:16 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNBoolean2bool(ctx, field.Selections, res)
2021-07-12 18:22:16 +00:00
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Meta_is_facebook_login_enabled(ctx context.Context, field graphql.CollectedField, obj *model.Meta) (ret graphql.Marshaler) {
2021-07-12 18:22:16 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Meta",
2021-07-12 18:22:16 +00:00
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.IsFacebookLoginEnabled, nil
2021-07-12 18:22:16 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
2021-07-12 18:22:16 +00:00
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(bool)
2021-07-12 18:22:16 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNBoolean2bool(ctx, field.Selections, res)
2021-07-12 18:22:16 +00:00
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Meta_is_github_login_enabled(ctx context.Context, field graphql.CollectedField, obj *model.Meta) (ret graphql.Marshaler) {
2021-07-12 18:22:16 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Meta",
2021-07-12 18:22:16 +00:00
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.IsGithubLoginEnabled, nil
2021-07-12 18:22:16 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
2021-07-12 18:22:16 +00:00
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(bool)
2021-07-12 18:22:16 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNBoolean2bool(ctx, field.Selections, res)
2021-07-12 18:22:16 +00:00
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Meta_is_email_verification_enabled(ctx context.Context, field graphql.CollectedField, obj *model.Meta) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Meta",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.IsEmailVerificationEnabled, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(bool)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNBoolean2bool(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Meta_is_basic_authentication_enabled(ctx context.Context, field graphql.CollectedField, obj *model.Meta) (ret graphql.Marshaler) {
2021-07-12 18:22:16 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Meta",
2021-07-12 18:22:16 +00:00
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.IsBasicAuthenticationEnabled, nil
2021-07-12 18:22:16 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
2021-07-12 18:22:16 +00:00
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(bool)
2021-07-12 18:22:16 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNBoolean2bool(ctx, field.Selections, res)
2021-07-12 18:22:16 +00:00
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Meta_is_magic_link_login_enabled(ctx context.Context, field graphql.CollectedField, obj *model.Meta) (ret graphql.Marshaler) {
2021-07-12 18:22:16 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Meta",
2021-07-12 18:22:16 +00:00
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.IsMagicLinkLoginEnabled, nil
2021-07-12 18:22:16 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
2021-07-12 18:22:16 +00:00
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(bool)
2021-07-12 18:22:16 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNBoolean2bool(ctx, field.Selections, res)
2021-07-12 18:22:16 +00:00
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Mutation_signup(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
2021-07-12 18:22:16 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Mutation",
2021-07-12 18:22:16 +00:00
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: true,
IsResolver: true,
2021-07-12 18:22:16 +00:00
}
ctx = graphql.WithFieldContext(ctx, fc)
2021-12-31 11:33:37 +00:00
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Mutation_signup_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
fc.Args = args
2021-07-12 18:22:16 +00:00
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return ec.resolvers.Mutation().Signup(rctx, args["params"].(model.SignUpInput))
2021-07-12 18:22:16 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
2021-07-12 18:22:16 +00:00
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*model.AuthResponse)
2021-07-12 18:22:16 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNAuthResponse2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐAuthResponse(ctx, field.Selections, res)
2021-07-12 18:22:16 +00:00
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Mutation_login(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
2021-07-12 18:22:16 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Mutation",
2021-07-12 18:22:16 +00:00
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: true,
IsResolver: true,
2021-07-12 18:22:16 +00:00
}
ctx = graphql.WithFieldContext(ctx, fc)
2021-12-31 11:33:37 +00:00
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Mutation_login_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
fc.Args = args
2021-07-12 18:22:16 +00:00
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return ec.resolvers.Mutation().Login(rctx, args["params"].(model.LoginInput))
2021-07-12 18:22:16 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
2021-07-12 18:22:16 +00:00
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*model.AuthResponse)
2021-07-12 18:22:16 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNAuthResponse2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐAuthResponse(ctx, field.Selections, res)
2021-07-12 18:22:16 +00:00
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Mutation_magic_link_login(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
2021-07-12 18:22:16 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Mutation",
2021-07-12 18:22:16 +00:00
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: true,
IsResolver: true,
2021-07-12 18:22:16 +00:00
}
ctx = graphql.WithFieldContext(ctx, fc)
2021-12-31 11:33:37 +00:00
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Mutation_magic_link_login_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
fc.Args = args
2021-07-12 18:22:16 +00:00
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return ec.resolvers.Mutation().MagicLinkLogin(rctx, args["params"].(model.MagicLinkLoginInput))
2021-07-12 18:22:16 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
2021-07-12 18:22:16 +00:00
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*model.Response)
2021-07-12 18:22:16 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNResponse2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐResponse(ctx, field.Selections, res)
2021-07-12 18:22:16 +00:00
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Mutation_logout(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
2021-07-12 18:22:16 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Mutation",
2021-07-12 18:22:16 +00:00
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: true,
IsResolver: true,
2021-07-12 18:22:16 +00:00
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return ec.resolvers.Mutation().Logout(rctx)
2021-07-12 18:22:16 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
2021-07-12 18:22:16 +00:00
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*model.Response)
2021-07-12 18:22:16 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNResponse2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐResponse(ctx, field.Selections, res)
2021-07-12 18:22:16 +00:00
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Mutation_update_profile(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
2021-07-12 18:22:16 +00:00
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Mutation",
2021-07-12 18:22:16 +00:00
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: true,
IsResolver: true,
2021-07-12 18:22:16 +00:00
}
ctx = graphql.WithFieldContext(ctx, fc)
2021-12-31 11:33:37 +00:00
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Mutation_update_profile_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
fc.Args = args
2021-07-12 18:22:16 +00:00
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return ec.resolvers.Mutation().UpdateProfile(rctx, args["params"].(model.UpdateProfileInput))
2021-07-12 18:22:16 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
2021-07-12 18:22:16 +00:00
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*model.Response)
2021-07-12 18:22:16 +00:00
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNResponse2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐResponse(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Mutation_verify_email(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Mutation",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: true,
IsResolver: true,
}
ctx = graphql.WithFieldContext(ctx, fc)
2021-12-31 11:33:37 +00:00
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Mutation_verify_email_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return ec.resolvers.Mutation().VerifyEmail(rctx, args["params"].(model.VerifyEmailInput))
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*model.AuthResponse)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNAuthResponse2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐAuthResponse(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Mutation_resend_verify_email(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Mutation",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: true,
IsResolver: true,
}
ctx = graphql.WithFieldContext(ctx, fc)
2021-12-31 11:33:37 +00:00
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Mutation_resend_verify_email_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return ec.resolvers.Mutation().ResendVerifyEmail(rctx, args["params"].(model.ResendVerifyEmailInput))
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*model.Response)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNResponse2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐResponse(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Mutation_forgot_password(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Mutation",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: true,
IsResolver: true,
}
ctx = graphql.WithFieldContext(ctx, fc)
2021-12-31 11:33:37 +00:00
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Mutation_forgot_password_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return ec.resolvers.Mutation().ForgotPassword(rctx, args["params"].(model.ForgotPasswordInput))
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*model.Response)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNResponse2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐResponse(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Mutation_reset_password(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Mutation",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: true,
IsResolver: true,
}
ctx = graphql.WithFieldContext(ctx, fc)
2021-12-31 11:33:37 +00:00
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Mutation_reset_password_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return ec.resolvers.Mutation().ResetPassword(rctx, args["params"].(model.ResetPasswordInput))
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*model.Response)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNResponse2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐResponse(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Mutation__delete_user(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Mutation",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: true,
IsResolver: true,
}
ctx = graphql.WithFieldContext(ctx, fc)
2021-12-31 11:33:37 +00:00
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Mutation__delete_user_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return ec.resolvers.Mutation().DeleteUser(rctx, args["params"].(model.DeleteUserInput))
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*model.Response)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNResponse2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐResponse(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Mutation__update_user(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Mutation",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: true,
IsResolver: true,
}
ctx = graphql.WithFieldContext(ctx, fc)
2021-12-31 11:33:37 +00:00
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Mutation__update_user_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return ec.resolvers.Mutation().UpdateUser(rctx, args["params"].(model.UpdateUserInput))
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*model.User)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNUser2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐUser(ctx, field.Selections, res)
}
2022-01-09 12:05:37 +00:00
func (ec *executionContext) _Mutation__admin_signup(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "Mutation",
Field: field,
Args: nil,
IsMethod: true,
IsResolver: true,
}
ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Mutation__admin_signup_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Mutation().AdminSignup(rctx, args["params"].(model.AdminSignupInput))
2022-01-09 12:05:37 +00:00
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*model.Response)
2022-01-09 12:05:37 +00:00
fc.Result = res
return ec.marshalNResponse2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐResponse(ctx, field.Selections, res)
2022-01-09 12:05:37 +00:00
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Mutation__admin_login(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Mutation",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: true,
IsResolver: true,
}
ctx = graphql.WithFieldContext(ctx, fc)
2021-12-31 11:33:37 +00:00
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Mutation__admin_login_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return ec.resolvers.Mutation().AdminLogin(rctx, args["params"].(model.AdminLoginInput))
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*model.Response)
fc.Result = res
return ec.marshalNResponse2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐResponse(ctx, field.Selections, res)
}
2021-12-31 17:36:06 +00:00
func (ec *executionContext) _Mutation__admin_logout(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "Mutation",
Field: field,
Args: nil,
IsMethod: true,
IsResolver: true,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return ec.resolvers.Mutation().AdminLogout(rctx)
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*model.Response)
fc.Result = res
return ec.marshalNResponse2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐResponse(ctx, field.Selections, res)
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Mutation__update_env(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Mutation",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: true,
IsResolver: true,
}
ctx = graphql.WithFieldContext(ctx, fc)
2021-12-31 11:33:37 +00:00
rawArgs := field.ArgumentMap(ec.Variables)
2022-01-17 07:42:46 +00:00
args, err := ec.field_Mutation__update_env_args(ctx, rawArgs)
2021-12-31 11:33:37 +00:00
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2022-01-17 07:42:46 +00:00
return ec.resolvers.Mutation().UpdateEnv(rctx, args["params"].(model.UpdateEnvInput))
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*model.Response)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNResponse2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐResponse(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Query_meta(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Query",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: true,
IsResolver: true,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return ec.resolvers.Query().Meta(rctx)
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*model.Meta)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNMeta2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐMeta(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Query_session(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Query",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: true,
IsResolver: true,
}
ctx = graphql.WithFieldContext(ctx, fc)
2021-12-31 11:33:37 +00:00
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Query_session_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return ec.resolvers.Query().Session(rctx, args["roles"].([]string))
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*model.AuthResponse)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNAuthResponse2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐAuthResponse(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Query_profile(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Query",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: true,
IsResolver: true,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return ec.resolvers.Query().Profile(rctx)
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*model.User)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNUser2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐUser(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Query__users(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Query",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: true,
IsResolver: true,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return ec.resolvers.Query().Users(rctx)
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.([]*model.User)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNUser2ᚕᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐUserᚄ(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Query__verification_requests(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Query",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: true,
IsResolver: true,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return ec.resolvers.Query().VerificationRequests(rctx)
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.([]*model.VerificationRequest)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNVerificationRequest2ᚕᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐVerificationRequestᚄ(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Query__admin_session(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Query",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: true,
IsResolver: true,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return ec.resolvers.Query().AdminSession(rctx)
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*model.Response)
fc.Result = res
return ec.marshalNResponse2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐResponse(ctx, field.Selections, res)
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Query__env(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Query",
Field: field,
Args: nil,
IsMethod: true,
2021-12-31 11:33:37 +00:00
IsResolver: true,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2022-01-17 07:42:46 +00:00
return ec.resolvers.Query().Env(rctx)
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
2022-01-17 07:42:46 +00:00
res := resTmp.(*model.Env)
fc.Result = res
2022-01-17 07:42:46 +00:00
return ec.marshalNEnv2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐEnv(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Query___type(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Query",
Field: field,
Args: nil,
IsMethod: true,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
2021-12-31 11:33:37 +00:00
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field_Query___type_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return ec.introspectType(args["name"].(string))
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*introspection.Type)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Query___schema(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Query",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: true,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return ec.introspectSchema()
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*introspection.Schema)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalO__Schema2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐSchema(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _Response_message(ctx context.Context, field graphql.CollectedField, obj *model.Response) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "Response",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.Message, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNString2string(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _User_id(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "User",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.ID, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNID2string(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _User_email(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "User",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.Email, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNString2string(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _User_email_verified(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "User",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.EmailVerified, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(bool)
fc.Result = res
return ec.marshalNBoolean2bool(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _User_signup_methods(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "User",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.SignupMethods, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNString2string(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _User_given_name(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "User",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.GivenName, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _User_family_name(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "User",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.FamilyName, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _User_middle_name(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "User",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.MiddleName, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _User_nickname(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "User",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.Nickname, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
res := resTmp.(*string)
fc.Result = res
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _User_preferred_username(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "User",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.PreferredUsername, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _User_gender(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "User",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.Gender, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _User_birthdate(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "User",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.Birthdate, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _User_phone_number(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "User",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.PhoneNumber, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _User_phone_number_verified(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "User",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.PhoneNumberVerified, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*bool)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOBoolean2ᚖbool(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _User_picture(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "User",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.Picture, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _User_roles(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "User",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.Roles, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.([]string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNString2ᚕstringᚄ(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _User_created_at(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "User",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.CreatedAt, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*int64)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOInt642ᚖint64(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _User_updated_at(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "User",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
2021-12-31 11:33:37 +00:00
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.UpdatedAt, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
2021-12-31 11:33:37 +00:00
if resTmp == nil {
return graphql.Null
}
res := resTmp.(*int64)
fc.Result = res
return ec.marshalOInt642ᚖint64(ctx, field.Selections, res)
}
func (ec *executionContext) _VerificationRequest_id(ctx context.Context, field graphql.CollectedField, obj *model.VerificationRequest) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "VerificationRequest",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.ID, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
2021-12-31 11:33:37 +00:00
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalNID2string(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _VerificationRequest_identifier(ctx context.Context, field graphql.CollectedField, obj *model.VerificationRequest) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "VerificationRequest",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.Identifier, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _VerificationRequest_token(ctx context.Context, field graphql.CollectedField, obj *model.VerificationRequest) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "VerificationRequest",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.Token, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*string)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _VerificationRequest_email(ctx context.Context, field graphql.CollectedField, obj *model.VerificationRequest) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "VerificationRequest",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
2021-12-31 11:33:37 +00:00
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Email, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
2021-12-31 11:33:37 +00:00
if resTmp == nil {
return graphql.Null
}
res := resTmp.(*string)
fc.Result = res
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) _VerificationRequest_expires(ctx context.Context, field graphql.CollectedField, obj *model.VerificationRequest) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "VerificationRequest",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.Expires, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*int64)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOInt642ᚖint64(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _VerificationRequest_created_at(ctx context.Context, field graphql.CollectedField, obj *model.VerificationRequest) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "VerificationRequest",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.CreatedAt, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*int64)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOInt642ᚖint64(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) _VerificationRequest_updated_at(ctx context.Context, field graphql.CollectedField, obj *model.VerificationRequest) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
2021-12-31 11:33:37 +00:00
Object: "VerificationRequest",
Field: field,
Args: nil,
2021-12-31 11:33:37 +00:00
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
2021-12-31 11:33:37 +00:00
return obj.UpdatedAt, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
2021-12-31 11:33:37 +00:00
res := resTmp.(*int64)
fc.Result = res
2021-12-31 11:33:37 +00:00
return ec.marshalOInt642ᚖint64(ctx, field.Selections, res)
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) ___Directive_name(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Directive",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Name, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) ___Directive_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Directive",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Description, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
res := resTmp.(string)
fc.Result = res
return ec.marshalOString2string(ctx, field.Selections, res)
}
func (ec *executionContext) ___Directive_locations(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Directive",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Locations, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]string)
fc.Result = res
return ec.marshalN__DirectiveLocation2ᚕstringᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) ___Directive_args(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Directive",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Args, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]introspection.InputValue)
fc.Result = res
return ec.marshalN__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) ___Directive_isRepeatable(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Directive",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.IsRepeatable, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(bool)
fc.Result = res
return ec.marshalNBoolean2bool(ctx, field.Selections, res)
}
func (ec *executionContext) ___EnumValue_name(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__EnumValue",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Name, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) ___EnumValue_description(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__EnumValue",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Description, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
res := resTmp.(string)
fc.Result = res
return ec.marshalOString2string(ctx, field.Selections, res)
}
func (ec *executionContext) ___EnumValue_isDeprecated(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__EnumValue",
Field: field,
Args: nil,
IsMethod: true,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.IsDeprecated(), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(bool)
fc.Result = res
return ec.marshalNBoolean2bool(ctx, field.Selections, res)
}
func (ec *executionContext) ___EnumValue_deprecationReason(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__EnumValue",
Field: field,
Args: nil,
IsMethod: true,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.DeprecationReason(), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
res := resTmp.(*string)
fc.Result = res
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) ___Field_name(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Field",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Name, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) ___Field_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Field",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Description, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
res := resTmp.(string)
fc.Result = res
return ec.marshalOString2string(ctx, field.Selections, res)
}
func (ec *executionContext) ___Field_args(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Field",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Args, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]introspection.InputValue)
fc.Result = res
return ec.marshalN__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) ___Field_type(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Field",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Type, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*introspection.Type)
fc.Result = res
return ec.marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
}
func (ec *executionContext) ___Field_isDeprecated(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Field",
Field: field,
Args: nil,
IsMethod: true,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.IsDeprecated(), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(bool)
fc.Result = res
return ec.marshalNBoolean2bool(ctx, field.Selections, res)
}
func (ec *executionContext) ___Field_deprecationReason(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Field",
Field: field,
Args: nil,
IsMethod: true,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.DeprecationReason(), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
res := resTmp.(*string)
fc.Result = res
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) ___InputValue_name(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__InputValue",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Name, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
fc.Result = res
return ec.marshalNString2string(ctx, field.Selections, res)
}
func (ec *executionContext) ___InputValue_description(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__InputValue",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Description, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
res := resTmp.(string)
fc.Result = res
return ec.marshalOString2string(ctx, field.Selections, res)
}
func (ec *executionContext) ___InputValue_type(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__InputValue",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Type, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*introspection.Type)
fc.Result = res
return ec.marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
}
func (ec *executionContext) ___InputValue_defaultValue(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__InputValue",
Field: field,
Args: nil,
IsMethod: false,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.DefaultValue, nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
res := resTmp.(*string)
fc.Result = res
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) ___Schema_types(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Schema",
Field: field,
Args: nil,
IsMethod: true,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Types(), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]introspection.Type)
fc.Result = res
return ec.marshalN__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) ___Schema_queryType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Schema",
Field: field,
Args: nil,
IsMethod: true,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.QueryType(), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(*introspection.Type)
fc.Result = res
return ec.marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
}
func (ec *executionContext) ___Schema_mutationType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Schema",
Field: field,
Args: nil,
IsMethod: true,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.MutationType(), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
res := resTmp.(*introspection.Type)
fc.Result = res
return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
}
func (ec *executionContext) ___Schema_subscriptionType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Schema",
Field: field,
Args: nil,
IsMethod: true,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.SubscriptionType(), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
res := resTmp.(*introspection.Type)
fc.Result = res
return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
}
func (ec *executionContext) ___Schema_directives(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Schema",
Field: field,
Args: nil,
IsMethod: true,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Directives(), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.([]introspection.Directive)
fc.Result = res
return ec.marshalN__Directive2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirectiveᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) ___Type_kind(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Type",
Field: field,
Args: nil,
IsMethod: true,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Kind(), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
if !graphql.HasFieldError(ctx, fc) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
res := resTmp.(string)
fc.Result = res
return ec.marshalN__TypeKind2string(ctx, field.Selections, res)
}
func (ec *executionContext) ___Type_name(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Type",
Field: field,
Args: nil,
IsMethod: true,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Name(), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
res := resTmp.(*string)
fc.Result = res
return ec.marshalOString2ᚖstring(ctx, field.Selections, res)
}
func (ec *executionContext) ___Type_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Type",
Field: field,
Args: nil,
IsMethod: true,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Description(), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
res := resTmp.(string)
fc.Result = res
return ec.marshalOString2string(ctx, field.Selections, res)
}
func (ec *executionContext) ___Type_fields(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Type",
Field: field,
Args: nil,
IsMethod: true,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field___Type_fields_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Fields(args["includeDeprecated"].(bool)), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
res := resTmp.([]introspection.Field)
fc.Result = res
return ec.marshalO__Field2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐFieldᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) ___Type_interfaces(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Type",
Field: field,
Args: nil,
IsMethod: true,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.Interfaces(), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
res := resTmp.([]introspection.Type)
fc.Result = res
return ec.marshalO__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) ___Type_possibleTypes(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Type",
Field: field,
Args: nil,
IsMethod: true,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.PossibleTypes(), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
res := resTmp.([]introspection.Type)
fc.Result = res
return ec.marshalO__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) ___Type_enumValues(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Type",
Field: field,
Args: nil,
IsMethod: true,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
rawArgs := field.ArgumentMap(ec.Variables)
args, err := ec.field___Type_enumValues_args(ctx, rawArgs)
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
fc.Args = args
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.EnumValues(args["includeDeprecated"].(bool)), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
res := resTmp.([]introspection.EnumValue)
fc.Result = res
return ec.marshalO__EnumValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValueᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) ___Type_inputFields(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Type",
Field: field,
Args: nil,
IsMethod: true,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.InputFields(), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
res := resTmp.([]introspection.InputValue)
fc.Result = res
return ec.marshalO__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx, field.Selections, res)
}
func (ec *executionContext) ___Type_ofType(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = graphql.Null
}
}()
fc := &graphql.FieldContext{
Object: "__Type",
Field: field,
Args: nil,
IsMethod: true,
IsResolver: false,
}
ctx = graphql.WithFieldContext(ctx, fc)
resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) {
ctx = rctx // use context from middleware stack in children
return obj.OfType(), nil
})
if err != nil {
ec.Error(ctx, err)
return graphql.Null
}
if resTmp == nil {
return graphql.Null
}
res := resTmp.(*introspection.Type)
fc.Result = res
return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res)
}
// endregion **************************** field.gotpl *****************************
// region **************************** input.gotpl *****************************
func (ec *executionContext) unmarshalInputAdminLoginInput(ctx context.Context, obj interface{}) (model.AdminLoginInput, error) {
var it model.AdminLoginInput
asMap := map[string]interface{}{}
for k, v := range obj.(map[string]interface{}) {
asMap[k] = v
}
for k, v := range asMap {
switch k {
2021-12-30 04:31:51 +00:00
case "admin_secret":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("admin_secret"))
it.AdminSecret, err = ec.unmarshalNString2string(ctx, v)
if err != nil {
return it, err
}
}
}
return it, nil
}
func (ec *executionContext) unmarshalInputAdminSignupInput(ctx context.Context, obj interface{}) (model.AdminSignupInput, error) {
var it model.AdminSignupInput
asMap := map[string]interface{}{}
for k, v := range obj.(map[string]interface{}) {
asMap[k] = v
}
for k, v := range asMap {
switch k {
case "admin_secret":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("admin_secret"))
it.AdminSecret, err = ec.unmarshalNString2string(ctx, v)
if err != nil {
return it, err
}
}
}
return it, nil
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) unmarshalInputDeleteUserInput(ctx context.Context, obj interface{}) (model.DeleteUserInput, error) {
var it model.DeleteUserInput
asMap := map[string]interface{}{}
for k, v := range obj.(map[string]interface{}) {
asMap[k] = v
}
for k, v := range asMap {
switch k {
case "email":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("email"))
it.Email, err = ec.unmarshalNString2string(ctx, v)
if err != nil {
return it, err
}
}
}
return it, nil
}
func (ec *executionContext) unmarshalInputForgotPasswordInput(ctx context.Context, obj interface{}) (model.ForgotPasswordInput, error) {
var it model.ForgotPasswordInput
asMap := map[string]interface{}{}
for k, v := range obj.(map[string]interface{}) {
asMap[k] = v
}
for k, v := range asMap {
switch k {
case "email":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("email"))
it.Email, err = ec.unmarshalNString2string(ctx, v)
2021-12-30 04:31:51 +00:00
if err != nil {
return it, err
}
}
}
return it, nil
}
2021-12-31 11:33:37 +00:00
func (ec *executionContext) unmarshalInputLoginInput(ctx context.Context, obj interface{}) (model.LoginInput, error) {
var it model.LoginInput
asMap := map[string]interface{}{}
for k, v := range obj.(map[string]interface{}) {
asMap[k] = v
}
for k, v := range asMap {
switch k {
case "email":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("email"))
it.Email, err = ec.unmarshalNString2string(ctx, v)
if err != nil {
return it, err
}
case "password":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("password"))
it.Password, err = ec.unmarshalNString2string(ctx, v)
if err != nil {
return it, err
}
case "roles":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("roles"))
it.Roles, err = ec.unmarshalOString2ᚕstringᚄ(ctx, v)
if err != nil {
return it, err
}
}
}
return it, nil
}
func (ec *executionContext) unmarshalInputMagicLinkLoginInput(ctx context.Context, obj interface{}) (model.MagicLinkLoginInput, error) {
var it model.MagicLinkLoginInput
asMap := map[string]interface{}{}
for k, v := range obj.(map[string]interface{}) {
asMap[k] = v
}
for k, v := range asMap {
switch k {
case "email":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("email"))
it.Email, err = ec.unmarshalNString2string(ctx, v)
if err != nil {
return it, err
}
case "roles":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("roles"))
it.Roles, err = ec.unmarshalOString2ᚕstringᚄ(ctx, v)
if err != nil {
return it, err
}
}
}
return it, nil
}
func (ec *executionContext) unmarshalInputResendVerifyEmailInput(ctx context.Context, obj interface{}) (model.ResendVerifyEmailInput, error) {
var it model.ResendVerifyEmailInput
asMap := map[string]interface{}{}
for k, v := range obj.(map[string]interface{}) {
asMap[k] = v
}
for k, v := range asMap {
switch k {
case "email":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("email"))
it.Email, err = ec.unmarshalNString2string(ctx, v)
if err != nil {
return it, err
}
case "identifier":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("identifier"))
it.Identifier, err = ec.unmarshalNString2string(ctx, v)
if err != nil {
return it, err
}
}
}
return it, nil
}
func (ec *executionContext) unmarshalInputResetPasswordInput(ctx context.Context, obj interface{}) (model.ResetPasswordInput, error) {
var it model.ResetPasswordInput
asMap := map[string]interface{}{}
for k, v := range obj.(map[string]interface{}) {
asMap[k] = v
}
for k, v := range asMap {
switch k {
case "token":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("token"))
it.Token, err = ec.unmarshalNString2string(ctx, v)
if err != nil {
return it, err
}
case "password":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("password"))
it.Password, err = ec.unmarshalNString2string(ctx, v)
if err != nil {
return it, err
}
case "confirm_password":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("confirm_password"))
it.ConfirmPassword, err = ec.unmarshalNString2string(ctx, v)
if err != nil {
return it, err
}
}
}
return it, nil
}
func (ec *executionContext) unmarshalInputSignUpInput(ctx context.Context, obj interface{}) (model.SignUpInput, error) {
var it model.SignUpInput
asMap := map[string]interface{}{}
for k, v := range obj.(map[string]interface{}) {
asMap[k] = v
}
2021-08-06 13:47:52 +00:00
for k, v := range asMap {
switch k {
case "email":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("email"))
it.Email, err = ec.unmarshalNString2string(ctx, v)
if err != nil {
return it, err
}
2021-12-31 11:33:37 +00:00
case "given_name":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("given_name"))
it.GivenName, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "family_name":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("family_name"))
it.FamilyName, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "middle_name":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("middle_name"))
it.MiddleName, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "nickname":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("nickname"))
it.Nickname, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "gender":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("gender"))
it.Gender, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "birthdate":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("birthdate"))
it.Birthdate, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "phone_number":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("phone_number"))
it.PhoneNumber, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "picture":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("picture"))
it.Picture, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "password":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("password"))
it.Password, err = ec.unmarshalNString2string(ctx, v)
if err != nil {
return it, err
}
case "confirm_password":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("confirm_password"))
it.ConfirmPassword, err = ec.unmarshalNString2string(ctx, v)
if err != nil {
return it, err
}
case "roles":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("roles"))
it.Roles, err = ec.unmarshalOString2ᚕstringᚄ(ctx, v)
if err != nil {
return it, err
}
2021-08-06 13:47:52 +00:00
}
}
return it, nil
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) unmarshalInputUpdateEnvInput(ctx context.Context, obj interface{}) (model.UpdateEnvInput, error) {
var it model.UpdateEnvInput
asMap := map[string]interface{}{}
for k, v := range obj.(map[string]interface{}) {
asMap[k] = v
}
for k, v := range asMap {
switch k {
2021-12-31 11:33:37 +00:00
case "ADMIN_SECRET":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("ADMIN_SECRET"))
it.AdminSecret, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "OLD_ADMIN_SECRET":
2022-01-17 07:42:46 +00:00
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("OLD_ADMIN_SECRET"))
it.OldAdminSecret, err = ec.unmarshalOString2ᚖstring(ctx, v)
2022-01-17 07:42:46 +00:00
if err != nil {
return it, err
}
2021-12-31 11:33:37 +00:00
case "SMTP_HOST":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("SMTP_HOST"))
it.SMTPHost, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
2021-12-31 11:33:37 +00:00
case "SMTP_PORT":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("SMTP_PORT"))
it.SMTPPort, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
2021-12-31 11:33:37 +00:00
case "SENDER_EMAIL":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("SENDER_EMAIL"))
it.SenderEmail, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "SENDER_PASSWORD":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("SENDER_PASSWORD"))
it.SenderPassword, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "JWT_TYPE":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("JWT_TYPE"))
it.JwtType, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "JWT_SECRET":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("JWT_SECRET"))
it.JwtSecret, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
2021-12-31 11:33:37 +00:00
case "ALLOWED_ORIGINS":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("ALLOWED_ORIGINS"))
it.AllowedOrigins, err = ec.unmarshalOString2ᚕstringᚄ(ctx, v)
if err != nil {
return it, err
}
2021-12-31 11:33:37 +00:00
case "AUTHORIZER_URL":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("AUTHORIZER_URL"))
it.AuthorizerURL, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "APP_URL":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("APP_URL"))
it.AppURL, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "REDIS_URL":
var err error
2021-07-15 09:43:00 +00:00
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("REDIS_URL"))
it.RedisURL, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "COOKIE_NAME":
2021-07-15 09:43:00 +00:00
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("COOKIE_NAME"))
it.CookieName, err = ec.unmarshalOString2ᚖstring(ctx, v)
2021-07-15 09:43:00 +00:00
if err != nil {
return it, err
}
2021-12-31 11:33:37 +00:00
case "RESET_PASSWORD_URL":
2021-07-15 09:43:00 +00:00
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("RESET_PASSWORD_URL"))
it.ResetPasswordURL, err = ec.unmarshalOString2ᚖstring(ctx, v)
2021-07-15 09:43:00 +00:00
if err != nil {
return it, err
}
2021-12-31 11:33:37 +00:00
case "DISABLE_EMAIL_VERIFICATION":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("DISABLE_EMAIL_VERIFICATION"))
it.DisableEmailVerification, err = ec.unmarshalOBoolean2ᚖbool(ctx, v)
if err != nil {
return it, err
}
2021-12-31 11:33:37 +00:00
case "DISABLE_BASIC_AUTHENTICATION":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("DISABLE_BASIC_AUTHENTICATION"))
it.DisableBasicAuthentication, err = ec.unmarshalOBoolean2ᚖbool(ctx, v)
if err != nil {
return it, err
}
case "DISABLE_MAGIC_LINK_LOGIN":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("DISABLE_MAGIC_LINK_LOGIN"))
it.DisableMagicLinkLogin, err = ec.unmarshalOBoolean2ᚖbool(ctx, v)
if err != nil {
return it, err
}
case "DISABLE_LOGIN_PAGE":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("DISABLE_LOGIN_PAGE"))
it.DisableLoginPage, err = ec.unmarshalOBoolean2ᚖbool(ctx, v)
if err != nil {
return it, err
}
case "ROLES":
2021-07-12 18:22:16 +00:00
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("ROLES"))
it.Roles, err = ec.unmarshalOString2ᚕstringᚄ(ctx, v)
2021-07-12 18:22:16 +00:00
if err != nil {
return it, err
}
2021-12-31 11:33:37 +00:00
case "PROTECTED_ROLES":
2021-07-12 18:22:16 +00:00
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("PROTECTED_ROLES"))
it.ProtectedRoles, err = ec.unmarshalOString2ᚕstringᚄ(ctx, v)
2021-07-12 18:22:16 +00:00
if err != nil {
return it, err
}
2021-12-31 11:33:37 +00:00
case "DEFAULT_ROLES":
2021-07-12 18:22:16 +00:00
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("DEFAULT_ROLES"))
it.DefaultRoles, err = ec.unmarshalOString2ᚕstringᚄ(ctx, v)
2021-07-12 18:22:16 +00:00
if err != nil {
return it, err
}
2021-12-31 11:33:37 +00:00
case "JWT_ROLE_CLAIM":
2021-07-12 18:22:16 +00:00
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("JWT_ROLE_CLAIM"))
it.JwtRoleClaim, err = ec.unmarshalOString2ᚖstring(ctx, v)
2021-07-12 18:22:16 +00:00
if err != nil {
return it, err
}
2021-12-31 11:33:37 +00:00
case "GOOGLE_CLIENT_ID":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("GOOGLE_CLIENT_ID"))
it.GoogleClientID, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
2021-12-31 11:33:37 +00:00
case "GOOGLE_CLIENT_SECRET":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("GOOGLE_CLIENT_SECRET"))
it.GoogleClientSecret, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
2021-12-31 11:33:37 +00:00
case "GITHUB_CLIENT_ID":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("GITHUB_CLIENT_ID"))
it.GithubClientID, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
2021-12-31 11:33:37 +00:00
case "GITHUB_CLIENT_SECRET":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("GITHUB_CLIENT_SECRET"))
it.GithubClientSecret, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
2021-12-31 11:33:37 +00:00
case "FACEBOOK_CLIENT_ID":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("FACEBOOK_CLIENT_ID"))
it.FacebookClientID, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
2021-12-31 11:33:37 +00:00
case "FACEBOOK_CLIENT_SECRET":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("FACEBOOK_CLIENT_SECRET"))
it.FacebookClientSecret, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
2021-12-31 11:33:37 +00:00
case "ORGANIZATION_NAME":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("ORGANIZATION_NAME"))
it.OrganizationName, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
2021-12-31 11:33:37 +00:00
case "ORGANIZATION_LOGO":
var err error
2021-12-31 11:33:37 +00:00
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("ORGANIZATION_LOGO"))
it.OrganizationLogo, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
}
}
return it, nil
}
func (ec *executionContext) unmarshalInputUpdateProfileInput(ctx context.Context, obj interface{}) (model.UpdateProfileInput, error) {
var it model.UpdateProfileInput
asMap := map[string]interface{}{}
for k, v := range obj.(map[string]interface{}) {
asMap[k] = v
}
for k, v := range asMap {
switch k {
case "old_password":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("old_password"))
it.OldPassword, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "new_password":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("new_password"))
it.NewPassword, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "confirm_new_password":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("confirm_new_password"))
it.ConfirmNewPassword, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "email":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("email"))
it.Email, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "given_name":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("given_name"))
it.GivenName, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "family_name":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("family_name"))
it.FamilyName, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "middle_name":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("middle_name"))
it.MiddleName, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "nickname":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("nickname"))
it.Nickname, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "gender":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("gender"))
it.Gender, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "birthdate":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("birthdate"))
it.Birthdate, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "phone_number":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("phone_number"))
it.PhoneNumber, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "picture":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("picture"))
it.Picture, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
}
}
return it, nil
}
func (ec *executionContext) unmarshalInputUpdateUserInput(ctx context.Context, obj interface{}) (model.UpdateUserInput, error) {
var it model.UpdateUserInput
asMap := map[string]interface{}{}
for k, v := range obj.(map[string]interface{}) {
asMap[k] = v
}
for k, v := range asMap {
switch k {
case "id":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id"))
it.ID, err = ec.unmarshalNID2string(ctx, v)
if err != nil {
return it, err
}
case "email":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("email"))
it.Email, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
2022-01-17 06:02:13 +00:00
case "email_verified":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("email_verified"))
it.EmailVerified, err = ec.unmarshalOBoolean2ᚖbool(ctx, v)
if err != nil {
return it, err
}
case "given_name":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("given_name"))
it.GivenName, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "family_name":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("family_name"))
it.FamilyName, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "middle_name":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("middle_name"))
it.MiddleName, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "nickname":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("nickname"))
it.Nickname, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "gender":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("gender"))
it.Gender, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "birthdate":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("birthdate"))
it.Birthdate, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "phone_number":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("phone_number"))
it.PhoneNumber, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "picture":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("picture"))
it.Picture, err = ec.unmarshalOString2ᚖstring(ctx, v)
if err != nil {
return it, err
}
case "roles":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("roles"))
it.Roles, err = ec.unmarshalOString2ᚕᚖstring(ctx, v)
if err != nil {
return it, err
}
}
}
return it, nil
}
func (ec *executionContext) unmarshalInputVerifyEmailInput(ctx context.Context, obj interface{}) (model.VerifyEmailInput, error) {
var it model.VerifyEmailInput
asMap := map[string]interface{}{}
for k, v := range obj.(map[string]interface{}) {
asMap[k] = v
}
for k, v := range asMap {
switch k {
case "token":
var err error
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("token"))
it.Token, err = ec.unmarshalNString2string(ctx, v)
if err != nil {
return it, err
}
2021-07-12 18:22:16 +00:00
}
}
return it, nil
2021-07-12 18:22:16 +00:00
}
// endregion **************************** input.gotpl *****************************
// region ************************** interface.gotpl ***************************
// endregion ************************** interface.gotpl ***************************
// region **************************** object.gotpl ****************************
var authResponseImplementors = []string{"AuthResponse"}
2021-07-12 18:22:16 +00:00
func (ec *executionContext) _AuthResponse(ctx context.Context, sel ast.SelectionSet, obj *model.AuthResponse) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, authResponseImplementors)
2021-07-12 18:22:16 +00:00
out := graphql.NewFieldSet(fields)
var invalids uint32
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("AuthResponse")
2021-07-12 18:22:16 +00:00
case "message":
out.Values[i] = ec._AuthResponse_message(ctx, field, obj)
2021-07-12 18:22:16 +00:00
if out.Values[i] == graphql.Null {
invalids++
}
case "access_token":
out.Values[i] = ec._AuthResponse_access_token(ctx, field, obj)
case "expires_at":
out.Values[i] = ec._AuthResponse_expires_at(ctx, field, obj)
case "user":
out.Values[i] = ec._AuthResponse_user(ctx, field, obj)
2021-07-12 18:22:16 +00:00
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch()
if invalids > 0 {
return graphql.Null
}
return out
}
2022-01-17 07:42:46 +00:00
var envImplementors = []string{"Env"}
2021-12-31 11:33:37 +00:00
2022-01-17 07:42:46 +00:00
func (ec *executionContext) _Env(ctx context.Context, sel ast.SelectionSet, obj *model.Env) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, envImplementors)
2021-12-31 11:33:37 +00:00
out := graphql.NewFieldSet(fields)
var invalids uint32
for i, field := range fields {
switch field.Name {
case "__typename":
2022-01-17 07:42:46 +00:00
out.Values[i] = graphql.MarshalString("Env")
2021-12-31 11:33:37 +00:00
case "ADMIN_SECRET":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_ADMIN_SECRET(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "SMTP_HOST":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_SMTP_HOST(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "SMTP_PORT":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_SMTP_PORT(ctx, field, obj)
case "SMTP_USERNAME":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_SMTP_USERNAME(ctx, field, obj)
case "SMTP_PASSWORD":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_SMTP_PASSWORD(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "SENDER_EMAIL":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_SENDER_EMAIL(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "JWT_TYPE":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_JWT_TYPE(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "JWT_SECRET":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_JWT_SECRET(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "ALLOWED_ORIGINS":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_ALLOWED_ORIGINS(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "AUTHORIZER_URL":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_AUTHORIZER_URL(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "APP_URL":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_APP_URL(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "REDIS_URL":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_REDIS_URL(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "COOKIE_NAME":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_COOKIE_NAME(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "RESET_PASSWORD_URL":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_RESET_PASSWORD_URL(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "DISABLE_EMAIL_VERIFICATION":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_DISABLE_EMAIL_VERIFICATION(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "DISABLE_BASIC_AUTHENTICATION":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_DISABLE_BASIC_AUTHENTICATION(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "DISABLE_MAGIC_LINK_LOGIN":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_DISABLE_MAGIC_LINK_LOGIN(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "DISABLE_LOGIN_PAGE":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_DISABLE_LOGIN_PAGE(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "ROLES":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_ROLES(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "PROTECTED_ROLES":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_PROTECTED_ROLES(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "DEFAULT_ROLES":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_DEFAULT_ROLES(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "JWT_ROLE_CLAIM":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_JWT_ROLE_CLAIM(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "GOOGLE_CLIENT_ID":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_GOOGLE_CLIENT_ID(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "GOOGLE_CLIENT_SECRET":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_GOOGLE_CLIENT_SECRET(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "GITHUB_CLIENT_ID":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_GITHUB_CLIENT_ID(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "GITHUB_CLIENT_SECRET":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_GITHUB_CLIENT_SECRET(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "FACEBOOK_CLIENT_ID":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_FACEBOOK_CLIENT_ID(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "FACEBOOK_CLIENT_SECRET":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_FACEBOOK_CLIENT_SECRET(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "ORGANIZATION_NAME":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_ORGANIZATION_NAME(ctx, field, obj)
2021-12-31 11:33:37 +00:00
case "ORGANIZATION_LOGO":
2022-01-17 07:42:46 +00:00
out.Values[i] = ec._Env_ORGANIZATION_LOGO(ctx, field, obj)
2021-12-31 11:33:37 +00:00
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch()
if invalids > 0 {
return graphql.Null
}
return out
}
var errorImplementors = []string{"Error"}
2021-07-12 18:22:16 +00:00
func (ec *executionContext) _Error(ctx context.Context, sel ast.SelectionSet, obj *model.Error) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, errorImplementors)
2021-07-12 18:22:16 +00:00
out := graphql.NewFieldSet(fields)
var invalids uint32
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("Error")
2021-07-12 18:22:16 +00:00
case "message":
out.Values[i] = ec._Error_message(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "reason":
out.Values[i] = ec._Error_reason(ctx, field, obj)
2021-07-12 18:22:16 +00:00
if out.Values[i] == graphql.Null {
invalids++
}
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch()
if invalids > 0 {
return graphql.Null
}
return out
}
var metaImplementors = []string{"Meta"}
func (ec *executionContext) _Meta(ctx context.Context, sel ast.SelectionSet, obj *model.Meta) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, metaImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("Meta")
case "version":
out.Values[i] = ec._Meta_version(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "is_google_login_enabled":
out.Values[i] = ec._Meta_is_google_login_enabled(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "is_facebook_login_enabled":
out.Values[i] = ec._Meta_is_facebook_login_enabled(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "is_github_login_enabled":
out.Values[i] = ec._Meta_is_github_login_enabled(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "is_email_verification_enabled":
out.Values[i] = ec._Meta_is_email_verification_enabled(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "is_basic_authentication_enabled":
out.Values[i] = ec._Meta_is_basic_authentication_enabled(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "is_magic_link_login_enabled":
out.Values[i] = ec._Meta_is_magic_link_login_enabled(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch()
if invalids > 0 {
return graphql.Null
}
return out
}
var mutationImplementors = []string{"Mutation"}
func (ec *executionContext) _Mutation(ctx context.Context, sel ast.SelectionSet) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, mutationImplementors)
ctx = graphql.WithFieldContext(ctx, &graphql.FieldContext{
Object: "Mutation",
})
out := graphql.NewFieldSet(fields)
var invalids uint32
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("Mutation")
case "signup":
out.Values[i] = ec._Mutation_signup(ctx, field)
if out.Values[i] == graphql.Null {
invalids++
}
case "login":
out.Values[i] = ec._Mutation_login(ctx, field)
if out.Values[i] == graphql.Null {
invalids++
}
case "magic_link_login":
out.Values[i] = ec._Mutation_magic_link_login(ctx, field)
if out.Values[i] == graphql.Null {
invalids++
}
2021-07-15 09:43:00 +00:00
case "logout":
out.Values[i] = ec._Mutation_logout(ctx, field)
if out.Values[i] == graphql.Null {
invalids++
}
case "update_profile":
out.Values[i] = ec._Mutation_update_profile(ctx, field)
if out.Values[i] == graphql.Null {
invalids++
}
case "verify_email":
out.Values[i] = ec._Mutation_verify_email(ctx, field)
if out.Values[i] == graphql.Null {
invalids++
}
case "resend_verify_email":
out.Values[i] = ec._Mutation_resend_verify_email(ctx, field)
if out.Values[i] == graphql.Null {
invalids++
}
case "forgot_password":
out.Values[i] = ec._Mutation_forgot_password(ctx, field)
if out.Values[i] == graphql.Null {
invalids++
}
case "reset_password":
out.Values[i] = ec._Mutation_reset_password(ctx, field)
if out.Values[i] == graphql.Null {
invalids++
}
case "_delete_user":
out.Values[i] = ec._Mutation__delete_user(ctx, field)
if out.Values[i] == graphql.Null {
invalids++
}
case "_update_user":
out.Values[i] = ec._Mutation__update_user(ctx, field)
2021-08-06 13:47:52 +00:00
if out.Values[i] == graphql.Null {
invalids++
}
2022-01-09 12:05:37 +00:00
case "_admin_signup":
out.Values[i] = ec._Mutation__admin_signup(ctx, field)
if out.Values[i] == graphql.Null {
invalids++
}
2021-12-30 04:31:51 +00:00
case "_admin_login":
out.Values[i] = ec._Mutation__admin_login(ctx, field)
2021-12-31 11:33:37 +00:00
if out.Values[i] == graphql.Null {
invalids++
}
2021-12-31 17:36:06 +00:00
case "_admin_logout":
out.Values[i] = ec._Mutation__admin_logout(ctx, field)
if out.Values[i] == graphql.Null {
invalids++
}
2022-01-17 07:42:46 +00:00
case "_update_env":
out.Values[i] = ec._Mutation__update_env(ctx, field)
2021-12-31 11:33:37 +00:00
if out.Values[i] == graphql.Null {
invalids++
}
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch()
if invalids > 0 {
return graphql.Null
}
return out
}
var queryImplementors = []string{"Query"}
func (ec *executionContext) _Query(ctx context.Context, sel ast.SelectionSet) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, queryImplementors)
ctx = graphql.WithFieldContext(ctx, &graphql.FieldContext{
Object: "Query",
})
out := graphql.NewFieldSet(fields)
var invalids uint32
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("Query")
case "meta":
field := field
out.Concurrently(i, func() (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query_meta(ctx, field)
if res == graphql.Null {
atomic.AddUint32(&invalids, 1)
}
return res
})
case "session":
field := field
out.Concurrently(i, func() (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query_session(ctx, field)
2021-12-31 11:33:37 +00:00
if res == graphql.Null {
atomic.AddUint32(&invalids, 1)
}
return res
})
case "profile":
field := field
out.Concurrently(i, func() (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query_profile(ctx, field)
if res == graphql.Null {
atomic.AddUint32(&invalids, 1)
}
return res
})
case "_users":
field := field
out.Concurrently(i, func() (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query__users(ctx, field)
if res == graphql.Null {
atomic.AddUint32(&invalids, 1)
}
return res
})
case "_verification_requests":
field := field
out.Concurrently(i, func() (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query__verification_requests(ctx, field)
if res == graphql.Null {
atomic.AddUint32(&invalids, 1)
}
return res
})
2021-12-30 04:31:51 +00:00
case "_admin_session":
field := field
out.Concurrently(i, func() (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
res = ec._Query__admin_session(ctx, field)
2021-12-31 11:33:37 +00:00
if res == graphql.Null {
atomic.AddUint32(&invalids, 1)
}
return res
})
2022-01-17 07:42:46 +00:00
case "_env":
2021-12-31 11:33:37 +00:00
field := field
out.Concurrently(i, func() (res graphql.Marshaler) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
}
}()
2022-01-17 07:42:46 +00:00
res = ec._Query__env(ctx, field)
2021-12-31 11:33:37 +00:00
if res == graphql.Null {
atomic.AddUint32(&invalids, 1)
}
2021-12-30 04:31:51 +00:00
return res
})
case "__type":
out.Values[i] = ec._Query___type(ctx, field)
case "__schema":
out.Values[i] = ec._Query___schema(ctx, field)
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch()
if invalids > 0 {
return graphql.Null
}
return out
}
2021-07-15 09:43:00 +00:00
var responseImplementors = []string{"Response"}
func (ec *executionContext) _Response(ctx context.Context, sel ast.SelectionSet, obj *model.Response) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, responseImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("Response")
case "message":
out.Values[i] = ec._Response_message(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch()
if invalids > 0 {
return graphql.Null
}
return out
}
2021-07-12 18:22:16 +00:00
var userImplementors = []string{"User"}
2021-07-12 18:22:16 +00:00
func (ec *executionContext) _User(ctx context.Context, sel ast.SelectionSet, obj *model.User) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, userImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
for i, field := range fields {
switch field.Name {
case "__typename":
2021-07-12 18:22:16 +00:00
out.Values[i] = graphql.MarshalString("User")
case "id":
2021-07-12 18:22:16 +00:00
out.Values[i] = ec._User_id(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
2021-07-12 18:22:16 +00:00
case "email":
out.Values[i] = ec._User_email(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "email_verified":
out.Values[i] = ec._User_email_verified(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "signup_methods":
out.Values[i] = ec._User_signup_methods(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "given_name":
out.Values[i] = ec._User_given_name(ctx, field, obj)
case "family_name":
out.Values[i] = ec._User_family_name(ctx, field, obj)
case "middle_name":
out.Values[i] = ec._User_middle_name(ctx, field, obj)
case "nickname":
out.Values[i] = ec._User_nickname(ctx, field, obj)
case "preferred_username":
out.Values[i] = ec._User_preferred_username(ctx, field, obj)
case "gender":
out.Values[i] = ec._User_gender(ctx, field, obj)
case "birthdate":
out.Values[i] = ec._User_birthdate(ctx, field, obj)
case "phone_number":
out.Values[i] = ec._User_phone_number(ctx, field, obj)
case "phone_number_verified":
out.Values[i] = ec._User_phone_number_verified(ctx, field, obj)
case "picture":
out.Values[i] = ec._User_picture(ctx, field, obj)
case "roles":
out.Values[i] = ec._User_roles(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "created_at":
out.Values[i] = ec._User_created_at(ctx, field, obj)
case "updated_at":
out.Values[i] = ec._User_updated_at(ctx, field, obj)
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch()
if invalids > 0 {
return graphql.Null
}
return out
}
2021-07-12 18:22:16 +00:00
var verificationRequestImplementors = []string{"VerificationRequest"}
2021-07-12 18:22:16 +00:00
func (ec *executionContext) _VerificationRequest(ctx context.Context, sel ast.SelectionSet, obj *model.VerificationRequest) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, verificationRequestImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
for i, field := range fields {
switch field.Name {
case "__typename":
2021-07-12 18:22:16 +00:00
out.Values[i] = graphql.MarshalString("VerificationRequest")
case "id":
2021-07-12 18:22:16 +00:00
out.Values[i] = ec._VerificationRequest_id(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
2021-07-12 18:22:16 +00:00
case "identifier":
out.Values[i] = ec._VerificationRequest_identifier(ctx, field, obj)
case "token":
out.Values[i] = ec._VerificationRequest_token(ctx, field, obj)
case "email":
out.Values[i] = ec._VerificationRequest_email(ctx, field, obj)
case "expires":
out.Values[i] = ec._VerificationRequest_expires(ctx, field, obj)
case "created_at":
out.Values[i] = ec._VerificationRequest_created_at(ctx, field, obj)
case "updated_at":
out.Values[i] = ec._VerificationRequest_updated_at(ctx, field, obj)
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch()
if invalids > 0 {
return graphql.Null
}
return out
}
var __DirectiveImplementors = []string{"__Directive"}
func (ec *executionContext) ___Directive(ctx context.Context, sel ast.SelectionSet, obj *introspection.Directive) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, __DirectiveImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("__Directive")
case "name":
out.Values[i] = ec.___Directive_name(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "description":
out.Values[i] = ec.___Directive_description(ctx, field, obj)
case "locations":
out.Values[i] = ec.___Directive_locations(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "args":
out.Values[i] = ec.___Directive_args(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "isRepeatable":
out.Values[i] = ec.___Directive_isRepeatable(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch()
if invalids > 0 {
return graphql.Null
}
return out
}
var __EnumValueImplementors = []string{"__EnumValue"}
func (ec *executionContext) ___EnumValue(ctx context.Context, sel ast.SelectionSet, obj *introspection.EnumValue) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, __EnumValueImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("__EnumValue")
case "name":
out.Values[i] = ec.___EnumValue_name(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "description":
out.Values[i] = ec.___EnumValue_description(ctx, field, obj)
case "isDeprecated":
out.Values[i] = ec.___EnumValue_isDeprecated(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "deprecationReason":
out.Values[i] = ec.___EnumValue_deprecationReason(ctx, field, obj)
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch()
if invalids > 0 {
return graphql.Null
}
return out
}
var __FieldImplementors = []string{"__Field"}
func (ec *executionContext) ___Field(ctx context.Context, sel ast.SelectionSet, obj *introspection.Field) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, __FieldImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("__Field")
case "name":
out.Values[i] = ec.___Field_name(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "description":
out.Values[i] = ec.___Field_description(ctx, field, obj)
case "args":
out.Values[i] = ec.___Field_args(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "type":
out.Values[i] = ec.___Field_type(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "isDeprecated":
out.Values[i] = ec.___Field_isDeprecated(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "deprecationReason":
out.Values[i] = ec.___Field_deprecationReason(ctx, field, obj)
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch()
if invalids > 0 {
return graphql.Null
}
return out
}
var __InputValueImplementors = []string{"__InputValue"}
func (ec *executionContext) ___InputValue(ctx context.Context, sel ast.SelectionSet, obj *introspection.InputValue) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, __InputValueImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("__InputValue")
case "name":
out.Values[i] = ec.___InputValue_name(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "description":
out.Values[i] = ec.___InputValue_description(ctx, field, obj)
case "type":
out.Values[i] = ec.___InputValue_type(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "defaultValue":
out.Values[i] = ec.___InputValue_defaultValue(ctx, field, obj)
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch()
if invalids > 0 {
return graphql.Null
}
return out
}
var __SchemaImplementors = []string{"__Schema"}
func (ec *executionContext) ___Schema(ctx context.Context, sel ast.SelectionSet, obj *introspection.Schema) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, __SchemaImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("__Schema")
case "types":
out.Values[i] = ec.___Schema_types(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "queryType":
out.Values[i] = ec.___Schema_queryType(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "mutationType":
out.Values[i] = ec.___Schema_mutationType(ctx, field, obj)
case "subscriptionType":
out.Values[i] = ec.___Schema_subscriptionType(ctx, field, obj)
case "directives":
out.Values[i] = ec.___Schema_directives(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch()
if invalids > 0 {
return graphql.Null
}
return out
}
var __TypeImplementors = []string{"__Type"}
func (ec *executionContext) ___Type(ctx context.Context, sel ast.SelectionSet, obj *introspection.Type) graphql.Marshaler {
fields := graphql.CollectFields(ec.OperationContext, sel, __TypeImplementors)
out := graphql.NewFieldSet(fields)
var invalids uint32
for i, field := range fields {
switch field.Name {
case "__typename":
out.Values[i] = graphql.MarshalString("__Type")
case "kind":
out.Values[i] = ec.___Type_kind(ctx, field, obj)
if out.Values[i] == graphql.Null {
invalids++
}
case "name":
out.Values[i] = ec.___Type_name(ctx, field, obj)
case "description":
out.Values[i] = ec.___Type_description(ctx, field, obj)
case "fields":
out.Values[i] = ec.___Type_fields(ctx, field, obj)
case "interfaces":
out.Values[i] = ec.___Type_interfaces(ctx, field, obj)
case "possibleTypes":
out.Values[i] = ec.___Type_possibleTypes(ctx, field, obj)
case "enumValues":
out.Values[i] = ec.___Type_enumValues(ctx, field, obj)
case "inputFields":
out.Values[i] = ec.___Type_inputFields(ctx, field, obj)
case "ofType":
out.Values[i] = ec.___Type_ofType(ctx, field, obj)
default:
panic("unknown field " + strconv.Quote(field.Name))
}
}
out.Dispatch()
if invalids > 0 {
return graphql.Null
}
return out
}
// endregion **************************** object.gotpl ****************************
// region ***************************** type.gotpl *****************************
2021-12-30 04:31:51 +00:00
func (ec *executionContext) unmarshalNAdminLoginInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐAdminLoginInput(ctx context.Context, v interface{}) (model.AdminLoginInput, error) {
res, err := ec.unmarshalInputAdminLoginInput(ctx, v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) unmarshalNAdminSignupInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐAdminSignupInput(ctx context.Context, v interface{}) (model.AdminSignupInput, error) {
res, err := ec.unmarshalInputAdminSignupInput(ctx, v)
return res, graphql.ErrorOnPath(ctx, err)
2021-12-31 11:33:37 +00:00
}
func (ec *executionContext) marshalNAuthResponse2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐAuthResponse(ctx context.Context, sel ast.SelectionSet, v model.AuthResponse) graphql.Marshaler {
return ec._AuthResponse(ctx, sel, &v)
}
func (ec *executionContext) marshalNAuthResponse2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐAuthResponse(ctx context.Context, sel ast.SelectionSet, v *model.AuthResponse) graphql.Marshaler {
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
return ec._AuthResponse(ctx, sel, v)
}
func (ec *executionContext) unmarshalNBoolean2bool(ctx context.Context, v interface{}) (bool, error) {
res, err := graphql.UnmarshalBoolean(v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalNBoolean2bool(ctx context.Context, sel ast.SelectionSet, v bool) graphql.Marshaler {
res := graphql.MarshalBoolean(v)
if res == graphql.Null {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
}
return res
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) unmarshalNDeleteUserInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐDeleteUserInput(ctx context.Context, v interface{}) (model.DeleteUserInput, error) {
res, err := ec.unmarshalInputDeleteUserInput(ctx, v)
return res, graphql.ErrorOnPath(ctx, err)
2021-12-31 11:33:37 +00:00
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) marshalNEnv2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐEnv(ctx context.Context, sel ast.SelectionSet, v model.Env) graphql.Marshaler {
return ec._Env(ctx, sel, &v)
}
func (ec *executionContext) marshalNEnv2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐEnv(ctx context.Context, sel ast.SelectionSet, v *model.Env) graphql.Marshaler {
2021-12-31 11:33:37 +00:00
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
2022-01-17 07:42:46 +00:00
return ec._Env(ctx, sel, v)
2021-08-06 13:47:52 +00:00
}
2021-07-28 06:23:37 +00:00
func (ec *executionContext) unmarshalNForgotPasswordInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐForgotPasswordInput(ctx context.Context, v interface{}) (model.ForgotPasswordInput, error) {
res, err := ec.unmarshalInputForgotPasswordInput(ctx, v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) unmarshalNID2string(ctx context.Context, v interface{}) (string, error) {
res, err := graphql.UnmarshalID(v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalNID2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler {
res := graphql.MarshalID(v)
if res == graphql.Null {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
}
return res
}
2021-07-28 06:23:37 +00:00
func (ec *executionContext) unmarshalNLoginInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐLoginInput(ctx context.Context, v interface{}) (model.LoginInput, error) {
res, err := ec.unmarshalInputLoginInput(ctx, v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) unmarshalNMagicLinkLoginInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐMagicLinkLoginInput(ctx context.Context, v interface{}) (model.MagicLinkLoginInput, error) {
res, err := ec.unmarshalInputMagicLinkLoginInput(ctx, v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalNMeta2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐMeta(ctx context.Context, sel ast.SelectionSet, v model.Meta) graphql.Marshaler {
return ec._Meta(ctx, sel, &v)
}
func (ec *executionContext) marshalNMeta2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐMeta(ctx context.Context, sel ast.SelectionSet, v *model.Meta) graphql.Marshaler {
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
return ec._Meta(ctx, sel, v)
}
2021-07-28 06:23:37 +00:00
func (ec *executionContext) unmarshalNResendVerifyEmailInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐResendVerifyEmailInput(ctx context.Context, v interface{}) (model.ResendVerifyEmailInput, error) {
res, err := ec.unmarshalInputResendVerifyEmailInput(ctx, v)
return res, graphql.ErrorOnPath(ctx, err)
}
2021-08-07 08:41:26 +00:00
func (ec *executionContext) unmarshalNResetPasswordInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐResetPasswordInput(ctx context.Context, v interface{}) (model.ResetPasswordInput, error) {
res, err := ec.unmarshalInputResetPasswordInput(ctx, v)
return res, graphql.ErrorOnPath(ctx, err)
}
2021-07-28 06:23:37 +00:00
func (ec *executionContext) marshalNResponse2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐResponse(ctx context.Context, sel ast.SelectionSet, v model.Response) graphql.Marshaler {
2021-07-15 09:43:00 +00:00
return ec._Response(ctx, sel, &v)
}
2021-07-28 06:23:37 +00:00
func (ec *executionContext) marshalNResponse2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐResponse(ctx context.Context, sel ast.SelectionSet, v *model.Response) graphql.Marshaler {
2021-07-15 09:43:00 +00:00
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
return ec._Response(ctx, sel, v)
}
2021-07-28 06:23:37 +00:00
func (ec *executionContext) unmarshalNSignUpInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐSignUpInput(ctx context.Context, v interface{}) (model.SignUpInput, error) {
2021-07-15 09:43:00 +00:00
res, err := ec.unmarshalInputSignUpInput(ctx, v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) unmarshalNString2string(ctx context.Context, v interface{}) (string, error) {
res, err := graphql.UnmarshalString(v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalNString2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler {
res := graphql.MarshalString(v)
if res == graphql.Null {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
}
return res
}
func (ec *executionContext) unmarshalNString2ᚕstringᚄ(ctx context.Context, v interface{}) ([]string, error) {
var vSlice []interface{}
if v != nil {
if tmp1, ok := v.([]interface{}); ok {
vSlice = tmp1
} else {
vSlice = []interface{}{v}
}
}
var err error
res := make([]string, len(vSlice))
for i := range vSlice {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i))
res[i], err = ec.unmarshalNString2string(ctx, vSlice[i])
if err != nil {
return nil, err
}
}
return res, nil
}
func (ec *executionContext) marshalNString2ᚕstringᚄ(ctx context.Context, sel ast.SelectionSet, v []string) graphql.Marshaler {
ret := make(graphql.Array, len(v))
for i := range v {
ret[i] = ec.marshalNString2string(ctx, sel, v[i])
}
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
2022-01-17 07:42:46 +00:00
func (ec *executionContext) unmarshalNUpdateEnvInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐUpdateEnvInput(ctx context.Context, v interface{}) (model.UpdateEnvInput, error) {
res, err := ec.unmarshalInputUpdateEnvInput(ctx, v)
2021-12-31 11:33:37 +00:00
return res, graphql.ErrorOnPath(ctx, err)
}
2021-07-28 06:23:37 +00:00
func (ec *executionContext) unmarshalNUpdateProfileInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐUpdateProfileInput(ctx context.Context, v interface{}) (model.UpdateProfileInput, error) {
res, err := ec.unmarshalInputUpdateProfileInput(ctx, v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) unmarshalNUpdateUserInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐUpdateUserInput(ctx context.Context, v interface{}) (model.UpdateUserInput, error) {
res, err := ec.unmarshalInputUpdateUserInput(ctx, v)
return res, graphql.ErrorOnPath(ctx, err)
}
2021-07-28 06:23:37 +00:00
func (ec *executionContext) marshalNUser2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐUser(ctx context.Context, sel ast.SelectionSet, v model.User) graphql.Marshaler {
return ec._User(ctx, sel, &v)
}
2021-07-28 06:23:37 +00:00
func (ec *executionContext) marshalNUser2ᚕᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐUserᚄ(ctx context.Context, sel ast.SelectionSet, v []*model.User) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
if !isLen1 {
wg.Add(len(v))
}
for i := range v {
i := i
fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = nil
}
}()
if !isLen1 {
defer wg.Done()
}
2021-07-28 06:23:37 +00:00
ret[i] = ec.marshalNUser2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐUser(ctx, sel, v[i])
}
if isLen1 {
f(i)
} else {
go f(i)
}
}
wg.Wait()
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
2021-07-28 06:23:37 +00:00
func (ec *executionContext) marshalNUser2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐUser(ctx context.Context, sel ast.SelectionSet, v *model.User) graphql.Marshaler {
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
return ec._User(ctx, sel, v)
}
2021-07-28 06:23:37 +00:00
func (ec *executionContext) marshalNVerificationRequest2ᚕᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐVerificationRequestᚄ(ctx context.Context, sel ast.SelectionSet, v []*model.VerificationRequest) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
if !isLen1 {
wg.Add(len(v))
}
for i := range v {
i := i
fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = nil
}
}()
if !isLen1 {
defer wg.Done()
}
2021-07-28 06:23:37 +00:00
ret[i] = ec.marshalNVerificationRequest2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐVerificationRequest(ctx, sel, v[i])
}
if isLen1 {
f(i)
} else {
go f(i)
}
}
wg.Wait()
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
2021-07-28 06:23:37 +00:00
func (ec *executionContext) marshalNVerificationRequest2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐVerificationRequest(ctx context.Context, sel ast.SelectionSet, v *model.VerificationRequest) graphql.Marshaler {
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
return ec._VerificationRequest(ctx, sel, v)
}
2021-07-28 06:23:37 +00:00
func (ec *executionContext) unmarshalNVerifyEmailInput2githubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐVerifyEmailInput(ctx context.Context, v interface{}) (model.VerifyEmailInput, error) {
res, err := ec.unmarshalInputVerifyEmailInput(ctx, v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalN__Directive2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirective(ctx context.Context, sel ast.SelectionSet, v introspection.Directive) graphql.Marshaler {
return ec.___Directive(ctx, sel, &v)
}
func (ec *executionContext) marshalN__Directive2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirectiveᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Directive) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
if !isLen1 {
wg.Add(len(v))
}
for i := range v {
i := i
fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = nil
}
}()
if !isLen1 {
defer wg.Done()
}
ret[i] = ec.marshalN__Directive2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirective(ctx, sel, v[i])
}
if isLen1 {
f(i)
} else {
go f(i)
}
}
wg.Wait()
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) unmarshalN__DirectiveLocation2string(ctx context.Context, v interface{}) (string, error) {
res, err := graphql.UnmarshalString(v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalN__DirectiveLocation2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler {
res := graphql.MarshalString(v)
if res == graphql.Null {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
}
return res
}
func (ec *executionContext) unmarshalN__DirectiveLocation2ᚕstringᚄ(ctx context.Context, v interface{}) ([]string, error) {
var vSlice []interface{}
if v != nil {
if tmp1, ok := v.([]interface{}); ok {
vSlice = tmp1
} else {
vSlice = []interface{}{v}
}
}
var err error
res := make([]string, len(vSlice))
for i := range vSlice {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i))
res[i], err = ec.unmarshalN__DirectiveLocation2string(ctx, vSlice[i])
if err != nil {
return nil, err
}
}
return res, nil
}
func (ec *executionContext) marshalN__DirectiveLocation2ᚕstringᚄ(ctx context.Context, sel ast.SelectionSet, v []string) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
if !isLen1 {
wg.Add(len(v))
}
for i := range v {
i := i
fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = nil
}
}()
if !isLen1 {
defer wg.Done()
}
ret[i] = ec.marshalN__DirectiveLocation2string(ctx, sel, v[i])
}
if isLen1 {
f(i)
} else {
go f(i)
}
}
wg.Wait()
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) marshalN__EnumValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValue(ctx context.Context, sel ast.SelectionSet, v introspection.EnumValue) graphql.Marshaler {
return ec.___EnumValue(ctx, sel, &v)
}
func (ec *executionContext) marshalN__Field2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐField(ctx context.Context, sel ast.SelectionSet, v introspection.Field) graphql.Marshaler {
return ec.___Field(ctx, sel, &v)
}
func (ec *executionContext) marshalN__InputValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx context.Context, sel ast.SelectionSet, v introspection.InputValue) graphql.Marshaler {
return ec.___InputValue(ctx, sel, &v)
}
func (ec *executionContext) marshalN__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.InputValue) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
if !isLen1 {
wg.Add(len(v))
}
for i := range v {
i := i
fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = nil
}
}()
if !isLen1 {
defer wg.Done()
}
ret[i] = ec.marshalN__InputValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx, sel, v[i])
}
if isLen1 {
f(i)
} else {
go f(i)
}
}
wg.Wait()
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) marshalN__Type2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v introspection.Type) graphql.Marshaler {
return ec.___Type(ctx, sel, &v)
}
func (ec *executionContext) marshalN__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Type) graphql.Marshaler {
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
if !isLen1 {
wg.Add(len(v))
}
for i := range v {
i := i
fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = nil
}
}()
if !isLen1 {
defer wg.Done()
}
ret[i] = ec.marshalN__Type2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, sel, v[i])
}
if isLen1 {
f(i)
} else {
go f(i)
}
}
wg.Wait()
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v *introspection.Type) graphql.Marshaler {
if v == nil {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
return graphql.Null
}
return ec.___Type(ctx, sel, v)
}
func (ec *executionContext) unmarshalN__TypeKind2string(ctx context.Context, v interface{}) (string, error) {
res, err := graphql.UnmarshalString(v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalN__TypeKind2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler {
res := graphql.MarshalString(v)
if res == graphql.Null {
if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) {
ec.Errorf(ctx, "must not be null")
}
}
return res
}
func (ec *executionContext) unmarshalOBoolean2bool(ctx context.Context, v interface{}) (bool, error) {
res, err := graphql.UnmarshalBoolean(v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalOBoolean2bool(ctx context.Context, sel ast.SelectionSet, v bool) graphql.Marshaler {
return graphql.MarshalBoolean(v)
}
func (ec *executionContext) unmarshalOBoolean2ᚖbool(ctx context.Context, v interface{}) (*bool, error) {
if v == nil {
return nil, nil
}
res, err := graphql.UnmarshalBoolean(v)
return &res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalOBoolean2ᚖbool(ctx context.Context, sel ast.SelectionSet, v *bool) graphql.Marshaler {
if v == nil {
return graphql.Null
}
return graphql.MarshalBoolean(*v)
}
2021-07-12 18:22:16 +00:00
func (ec *executionContext) unmarshalOInt642ᚖint64(ctx context.Context, v interface{}) (*int64, error) {
if v == nil {
return nil, nil
}
res, err := graphql.UnmarshalInt64(v)
return &res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalOInt642ᚖint64(ctx context.Context, sel ast.SelectionSet, v *int64) graphql.Marshaler {
if v == nil {
return graphql.Null
}
return graphql.MarshalInt64(*v)
}
func (ec *executionContext) unmarshalOString2string(ctx context.Context, v interface{}) (string, error) {
res, err := graphql.UnmarshalString(v)
return res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalOString2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler {
return graphql.MarshalString(v)
}
func (ec *executionContext) unmarshalOString2ᚕstringᚄ(ctx context.Context, v interface{}) ([]string, error) {
if v == nil {
return nil, nil
}
var vSlice []interface{}
if v != nil {
if tmp1, ok := v.([]interface{}); ok {
vSlice = tmp1
} else {
vSlice = []interface{}{v}
}
}
var err error
res := make([]string, len(vSlice))
for i := range vSlice {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i))
res[i], err = ec.unmarshalNString2string(ctx, vSlice[i])
if err != nil {
return nil, err
}
}
return res, nil
}
func (ec *executionContext) marshalOString2ᚕstringᚄ(ctx context.Context, sel ast.SelectionSet, v []string) graphql.Marshaler {
if v == nil {
return graphql.Null
}
ret := make(graphql.Array, len(v))
for i := range v {
ret[i] = ec.marshalNString2string(ctx, sel, v[i])
}
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) unmarshalOString2ᚕᚖstring(ctx context.Context, v interface{}) ([]*string, error) {
if v == nil {
return nil, nil
}
var vSlice []interface{}
if v != nil {
if tmp1, ok := v.([]interface{}); ok {
vSlice = tmp1
} else {
vSlice = []interface{}{v}
}
}
var err error
res := make([]*string, len(vSlice))
for i := range vSlice {
ctx := graphql.WithPathContext(ctx, graphql.NewPathWithIndex(i))
res[i], err = ec.unmarshalOString2ᚖstring(ctx, vSlice[i])
if err != nil {
return nil, err
}
}
return res, nil
}
func (ec *executionContext) marshalOString2ᚕᚖstring(ctx context.Context, sel ast.SelectionSet, v []*string) graphql.Marshaler {
if v == nil {
return graphql.Null
}
ret := make(graphql.Array, len(v))
for i := range v {
ret[i] = ec.marshalOString2ᚖstring(ctx, sel, v[i])
}
return ret
}
func (ec *executionContext) unmarshalOString2ᚖstring(ctx context.Context, v interface{}) (*string, error) {
if v == nil {
return nil, nil
}
res, err := graphql.UnmarshalString(v)
return &res, graphql.ErrorOnPath(ctx, err)
}
func (ec *executionContext) marshalOString2ᚖstring(ctx context.Context, sel ast.SelectionSet, v *string) graphql.Marshaler {
if v == nil {
return graphql.Null
}
return graphql.MarshalString(*v)
}
2021-07-28 06:23:37 +00:00
func (ec *executionContext) marshalOUser2ᚖgithubᚗcomᚋauthorizerdevᚋauthorizerᚋserverᚋgraphᚋmodelᚐUser(ctx context.Context, sel ast.SelectionSet, v *model.User) graphql.Marshaler {
2021-07-12 18:22:16 +00:00
if v == nil {
return graphql.Null
}
return ec._User(ctx, sel, v)
}
func (ec *executionContext) marshalO__EnumValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValueᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.EnumValue) graphql.Marshaler {
if v == nil {
return graphql.Null
}
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
if !isLen1 {
wg.Add(len(v))
}
for i := range v {
i := i
fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = nil
}
}()
if !isLen1 {
defer wg.Done()
}
ret[i] = ec.marshalN__EnumValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValue(ctx, sel, v[i])
}
if isLen1 {
f(i)
} else {
go f(i)
}
}
wg.Wait()
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) marshalO__Field2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐFieldᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Field) graphql.Marshaler {
if v == nil {
return graphql.Null
}
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
if !isLen1 {
wg.Add(len(v))
}
for i := range v {
i := i
fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = nil
}
}()
if !isLen1 {
defer wg.Done()
}
ret[i] = ec.marshalN__Field2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐField(ctx, sel, v[i])
}
if isLen1 {
f(i)
} else {
go f(i)
}
}
wg.Wait()
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) marshalO__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.InputValue) graphql.Marshaler {
if v == nil {
return graphql.Null
}
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
if !isLen1 {
wg.Add(len(v))
}
for i := range v {
i := i
fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = nil
}
}()
if !isLen1 {
defer wg.Done()
}
ret[i] = ec.marshalN__InputValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx, sel, v[i])
}
if isLen1 {
f(i)
} else {
go f(i)
}
}
wg.Wait()
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) marshalO__Schema2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐSchema(ctx context.Context, sel ast.SelectionSet, v *introspection.Schema) graphql.Marshaler {
if v == nil {
return graphql.Null
}
return ec.___Schema(ctx, sel, v)
}
func (ec *executionContext) marshalO__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Type) graphql.Marshaler {
if v == nil {
return graphql.Null
}
ret := make(graphql.Array, len(v))
var wg sync.WaitGroup
isLen1 := len(v) == 1
if !isLen1 {
wg.Add(len(v))
}
for i := range v {
i := i
fc := &graphql.FieldContext{
Index: &i,
Result: &v[i],
}
ctx := graphql.WithFieldContext(ctx, fc)
f := func(i int) {
defer func() {
if r := recover(); r != nil {
ec.Error(ctx, ec.Recover(ctx, r))
ret = nil
}
}()
if !isLen1 {
defer wg.Done()
}
ret[i] = ec.marshalN__Type2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, sel, v[i])
}
if isLen1 {
f(i)
} else {
go f(i)
}
}
wg.Wait()
for _, e := range ret {
if e == graphql.Null {
return graphql.Null
}
}
return ret
}
func (ec *executionContext) marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v *introspection.Type) graphql.Marshaler {
if v == nil {
return graphql.Null
}
return ec.___Type(ctx, sel, v)
}
// endregion ***************************** type.gotpl *****************************