├── .gitignore ├── graph ├── schema.graphql ├── resolver.go ├── model │ └── models_gen.go ├── schema.graphqls ├── schema.resolvers.go └── generated │ └── generated.go ├── internal ├── pkg │ └── db │ │ ├── migrations │ │ └── mysql │ │ │ ├── 000001_create_users_table.down.sql │ │ │ ├── 000002_create_links_table.down.sql │ │ │ ├── 000001_create_users_table.up.sql │ │ │ └── 000002_create_links_table.up.sql │ │ └── mysql │ │ └── mysql.go ├── users │ ├── errors.go │ └── users.go ├── auth │ └── middleware.go └── links │ └── links.go ├── go.mod ├── server.go ├── pkg └── jwt │ └── jwt.go ├── gqlgen.yml ├── README.md └── go.sum /.gitignore: -------------------------------------------------------------------------------- 1 | .idea -------------------------------------------------------------------------------- /graph/schema.graphql: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /internal/pkg/db/migrations/mysql/000001_create_users_table.down.sql: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /internal/pkg/db/migrations/mysql/000002_create_links_table.down.sql: -------------------------------------------------------------------------------- 1 | -------------------------------------------------------------------------------- /internal/users/errors.go: -------------------------------------------------------------------------------- 1 | package users 2 | 3 | type WrongUsernameOrPasswordError struct{} 4 | 5 | func (m *WrongUsernameOrPasswordError) Error() string { 6 | return "wrong username or password" 7 | } 8 | -------------------------------------------------------------------------------- /graph/resolver.go: -------------------------------------------------------------------------------- 1 | package graph 2 | 3 | // This file will not be regenerated automatically. 4 | // 5 | // It serves as dependency injection for your app, add any dependencies you require here. 6 | 7 | type Resolver struct{} 8 | -------------------------------------------------------------------------------- /internal/pkg/db/migrations/mysql/000001_create_users_table.up.sql: -------------------------------------------------------------------------------- 1 | CREATE TABLE IF NOT EXISTS Users( 2 | ID INT NOT NULL UNIQUE AUTO_INCREMENT, 3 | Username VARCHAR (127) NOT NULL UNIQUE, 4 | Password VARCHAR (127) NOT NULL, 5 | PRIMARY KEY (ID) 6 | ) 7 | -------------------------------------------------------------------------------- /internal/pkg/db/migrations/mysql/000002_create_links_table.up.sql: -------------------------------------------------------------------------------- 1 | CREATE TABLE IF NOT EXISTS Links( 2 | ID INT NOT NULL UNIQUE AUTO_INCREMENT, 3 | Title VARCHAR (255) , 4 | Address VARCHAR (255) , 5 | UserID INT , 6 | FOREIGN KEY (UserID) REFERENCES Users(ID) , 7 | PRIMARY KEY (ID) 8 | ) -------------------------------------------------------------------------------- /graph/model/models_gen.go: -------------------------------------------------------------------------------- 1 | // Code generated by github.com/99designs/gqlgen, DO NOT EDIT. 2 | 3 | package model 4 | 5 | type Link struct { 6 | ID string `json:"id"` 7 | Title string `json:"title"` 8 | Address string `json:"address"` 9 | User *User `json:"user"` 10 | } 11 | 12 | type Login struct { 13 | Username string `json:"username"` 14 | Password string `json:"password"` 15 | } 16 | 17 | type NewLink struct { 18 | Title string `json:"title"` 19 | Address string `json:"address"` 20 | } 21 | 22 | type NewUser struct { 23 | Username string `json:"username"` 24 | Password string `json:"password"` 25 | } 26 | 27 | type RefreshTokenInput struct { 28 | Token string `json:"token"` 29 | } 30 | 31 | type User struct { 32 | ID string `json:"id"` 33 | Name string `json:"name"` 34 | } 35 | -------------------------------------------------------------------------------- /graph/schema.graphqls: -------------------------------------------------------------------------------- 1 | type Link { 2 | id: ID! 3 | title: String! 4 | address: String! 5 | user: User! 6 | } 7 | 8 | type User { 9 | id: ID! 10 | name: String! 11 | } 12 | 13 | type Query { 14 | links: [Link!]! 15 | } 16 | 17 | input NewLink { 18 | title: String! 19 | address: String! 20 | } 21 | 22 | input RefreshTokenInput{ 23 | token: String! 24 | } 25 | 26 | input NewUser { 27 | username: String! 28 | password: String! 29 | } 30 | 31 | input Login { 32 | username: String! 33 | password: String! 34 | } 35 | 36 | type Mutation { 37 | createLink(input: NewLink!): Link! 38 | createUser(input: NewUser!): String! 39 | login(input: Login!): String! 40 | # we'll talk about this in authentication section 41 | refreshToken(input: RefreshTokenInput!): String! 42 | } 43 | -------------------------------------------------------------------------------- /go.mod: -------------------------------------------------------------------------------- 1 | module github.com/glyphack/graphlq-golang 2 | 3 | go 1.13 4 | 5 | require ( 6 | github.com/99designs/gqlgen v0.11.3 7 | github.com/Microsoft/go-winio v0.4.14 // indirect 8 | github.com/dgrijalva/jwt-go v3.2.0+incompatible 9 | github.com/docker/distribution v2.7.1+incompatible // indirect 10 | github.com/docker/docker v1.13.1 // indirect 11 | github.com/docker/go-connections v0.4.0 // indirect 12 | github.com/docker/go-units v0.4.0 // indirect 13 | github.com/go-chi/chi v3.3.2+incompatible 14 | github.com/go-sql-driver/mysql v1.5.0 15 | github.com/golang-migrate/migrate v3.5.4+incompatible 16 | github.com/golang-migrate/migrate/v4 v4.12.2 // indirect 17 | github.com/opencontainers/go-digest v1.0.0-rc1 // indirect 18 | github.com/urfave/cli v1.20.0 // indirect 19 | github.com/vektah/gqlparser v1.3.1 // indirect 20 | github.com/vektah/gqlparser/v2 v2.0.1 21 | golang.org/x/crypto v0.0.0-20200709230013-948cd5f35899 22 | ) 23 | -------------------------------------------------------------------------------- /internal/pkg/db/mysql/mysql.go: -------------------------------------------------------------------------------- 1 | package database 2 | 3 | import ( 4 | "database/sql" 5 | _ "github.com/go-sql-driver/mysql" 6 | "github.com/golang-migrate/migrate" 7 | "github.com/golang-migrate/migrate/database/mysql" 8 | _ "github.com/golang-migrate/migrate/source/file" 9 | "log" 10 | ) 11 | 12 | var Db *sql.DB 13 | 14 | func InitDB() { 15 | db, err := sql.Open("mysql", "root:dbpass@(172.17.0.2:3306)/hackernews") 16 | if err != nil { 17 | log.Panic(err) 18 | } 19 | 20 | if err = db.Ping(); err != nil { 21 | log.Panic(err) 22 | } 23 | Db = db 24 | } 25 | 26 | func CloseDB() error { 27 | return Db.Close() 28 | } 29 | 30 | func Migrate() { 31 | if err := Db.Ping(); err != nil { 32 | log.Fatal(err) 33 | } 34 | driver, _ := mysql.WithInstance(Db, &mysql.Config{}) 35 | m, _ := migrate.NewWithDatabaseInstance( 36 | "file://internal/pkg/db/migrations/mysql", 37 | "mysql", 38 | driver, 39 | ) 40 | if err := m.Up(); err != nil && err != migrate.ErrNoChange { 41 | log.Fatal(err) 42 | } 43 | 44 | } 45 | -------------------------------------------------------------------------------- /server.go: -------------------------------------------------------------------------------- 1 | package main 2 | 3 | import ( 4 | "log" 5 | "net/http" 6 | "os" 7 | 8 | "github.com/glyphack/graphlq-golang/graph" 9 | "github.com/glyphack/graphlq-golang/graph/generated" 10 | "github.com/glyphack/graphlq-golang/internal/auth" 11 | _ "github.com/glyphack/graphlq-golang/internal/auth" 12 | database "github.com/glyphack/graphlq-golang/internal/pkg/db/mysql" 13 | 14 | "github.com/99designs/gqlgen/graphql/handler" 15 | "github.com/99designs/gqlgen/graphql/playground" 16 | "github.com/go-chi/chi" 17 | ) 18 | 19 | const defaultPort = "8080" 20 | 21 | func main() { 22 | port := os.Getenv("PORT") 23 | if port == "" { 24 | port = defaultPort 25 | } 26 | 27 | router := chi.NewRouter() 28 | 29 | router.Use(auth.Middleware()) 30 | 31 | database.InitDB() 32 | defer database.CloseDB() 33 | database.Migrate() 34 | server := handler.NewDefaultServer(generated.NewExecutableSchema(generated.Config{Resolvers: &graph.Resolver{}})) 35 | router.Handle("/", playground.Handler("GraphQL playground", "/query")) 36 | router.Handle("/query", server) 37 | 38 | log.Printf("connect to http://localhost:%s/ for GraphQL playground", port) 39 | log.Fatal(http.ListenAndServe(":"+port, router)) 40 | } 41 | -------------------------------------------------------------------------------- /pkg/jwt/jwt.go: -------------------------------------------------------------------------------- 1 | package jwt 2 | 3 | import ( 4 | "github.com/dgrijalva/jwt-go" 5 | "log" 6 | "time" 7 | ) 8 | 9 | // secret key being used to sign tokens 10 | var ( 11 | SecretKey = []byte("secret") 12 | ) 13 | 14 | //data we save in each token 15 | type Claims struct { 16 | username string 17 | jwt.StandardClaims 18 | } 19 | 20 | //GenerateToken generates a jwt token and assign a username to it's claims and return it 21 | func GenerateToken(username string) (string, error) { 22 | token := jwt.New(jwt.SigningMethodHS256) 23 | /* Create a map to store our claims */ 24 | claims := token.Claims.(jwt.MapClaims) 25 | /* Set token claims */ 26 | claims["username"] = username 27 | claims["exp"] = time.Now().Add(time.Hour * 24).Unix() 28 | tokenString, err := token.SignedString(SecretKey) 29 | if err != nil { 30 | log.Fatal("Error in Generating key") 31 | return "", err 32 | } 33 | return tokenString, nil 34 | } 35 | 36 | //ParseToken parses a jwt token and returns the username it it's claims 37 | func ParseToken(tokenStr string) (string, error) { 38 | token, err := jwt.Parse(tokenStr, func(token *jwt.Token) (interface{}, error) { 39 | return SecretKey, nil 40 | }) 41 | if claims, ok := token.Claims.(jwt.MapClaims); ok && token.Valid { 42 | username := claims["username"].(string) 43 | return username, nil 44 | } else { 45 | return "", err 46 | } 47 | } 48 | -------------------------------------------------------------------------------- /internal/auth/middleware.go: -------------------------------------------------------------------------------- 1 | package auth 2 | 3 | import ( 4 | "context" 5 | "net/http" 6 | "strconv" 7 | 8 | "github.com/glyphack/graphlq-golang/internal/users" 9 | "github.com/glyphack/graphlq-golang/pkg/jwt" 10 | ) 11 | 12 | var userCtxKey = &contextKey{"user"} 13 | 14 | type contextKey struct { 15 | name string 16 | } 17 | 18 | func Middleware() func(http.Handler) http.Handler { 19 | return func(next http.Handler) http.Handler { 20 | return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { 21 | header := r.Header.Get("Authorization") 22 | 23 | // Allow unauthenticated users in 24 | if header == "" { 25 | next.ServeHTTP(w, r) 26 | return 27 | } 28 | 29 | //validate jwt token 30 | tokenStr := header 31 | username, err := jwt.ParseToken(tokenStr) 32 | if err != nil { 33 | http.Error(w, "Invalid token", http.StatusForbidden) 34 | return 35 | } 36 | 37 | // create user and check if user exists in db 38 | user := users.User{Username: username} 39 | id, err := users.GetUserIdByUsername(username) 40 | if err != nil { 41 | next.ServeHTTP(w, r) 42 | return 43 | } 44 | user.ID = strconv.Itoa(id) 45 | // put it in context 46 | ctx := context.WithValue(r.Context(), userCtxKey, &user) 47 | 48 | // and call the next with our new context 49 | r = r.WithContext(ctx) 50 | next.ServeHTTP(w, r) 51 | }) 52 | } 53 | } 54 | 55 | // ForContext finds the user from the context. REQUIRES Middleware to have run. 56 | func ForContext(ctx context.Context) *users.User { 57 | raw, _ := ctx.Value(userCtxKey).(*users.User) 58 | return raw 59 | } 60 | -------------------------------------------------------------------------------- /internal/links/links.go: -------------------------------------------------------------------------------- 1 | package links 2 | 3 | import ( 4 | database "github.com/glyphack/graphlq-golang/internal/pkg/db/mysql" 5 | "github.com/glyphack/graphlq-golang/internal/users" 6 | "log" 7 | ) 8 | 9 | // #1 10 | type Link struct { 11 | ID string 12 | Title string 13 | Address string 14 | User *users.User 15 | } 16 | 17 | //#2 18 | func (link Link) Save() int64 { 19 | //#3 20 | stmt, err := database.Db.Prepare("INSERT INTO Links(Title,Address, UserID) VALUES(?,?, ?)") 21 | if err != nil { 22 | log.Fatal(err) 23 | } 24 | //#4 25 | res, err := stmt.Exec(link.Title, link.Address, link.User.ID) 26 | if err != nil { 27 | log.Fatal(err) 28 | } 29 | //#5 30 | id, err := res.LastInsertId() 31 | if err != nil { 32 | log.Fatal("Error:", err.Error()) 33 | } 34 | log.Print("Row inserted!") 35 | return id 36 | } 37 | 38 | func GetAll() []Link { 39 | stmt, err := database.Db.Prepare("select L.id, L.title, L.address, L.UserID, U.Username from Links L inner join Users U on L.UserID = U.ID") 40 | if err != nil { 41 | log.Fatal(err) 42 | } 43 | defer stmt.Close() 44 | rows, err := stmt.Query() 45 | if err != nil { 46 | log.Fatal(err) 47 | } 48 | defer rows.Close() 49 | var links []Link 50 | var username string 51 | var id string 52 | for rows.Next() { 53 | var link Link 54 | err := rows.Scan(&link.ID, &link.Title, &link.Address, &id, &username) 55 | if err != nil { 56 | log.Fatal(err) 57 | } 58 | link.User = &users.User{ 59 | ID: id, 60 | Username: username, 61 | } 62 | links = append(links, link) 63 | } 64 | if err = rows.Err(); err != nil { 65 | log.Fatal(err) 66 | } 67 | return links 68 | } 69 | -------------------------------------------------------------------------------- /gqlgen.yml: -------------------------------------------------------------------------------- 1 | # Where are all the schema files located? globs are supported eg src/**/*.graphqls 2 | schema: 3 | - graph/*.graphqls 4 | 5 | # Where should the generated server code go? 6 | exec: 7 | filename: graph/generated/generated.go 8 | package: generated 9 | 10 | # Uncomment to enable federation 11 | # federation: 12 | # filename: graph/generated/federation.go 13 | # package: generated 14 | 15 | # Where should any generated models go? 16 | model: 17 | filename: graph/model/models_gen.go 18 | package: model 19 | 20 | # Where should the resolver implementations go? 21 | resolver: 22 | layout: follow-schema 23 | dir: graph 24 | package: graph 25 | 26 | # Optional: turn on use `gqlgen:"fieldName"` tags in your models 27 | # struct_tag: json 28 | 29 | # Optional: turn on to use []Thing instead of []*Thing 30 | # omit_slice_element_pointers: false 31 | 32 | # Optional: set to speed up generation time by not performing a final validation pass. 33 | # skip_validation: true 34 | 35 | # gqlgen will search for any type names in the schema in these go packages 36 | # if they match it will use them, otherwise it will generate them. 37 | autobind: 38 | - "github.com/glyphack/graphlq-golang/graph/model" 39 | 40 | # This section declares type mapping between the GraphQL and go type systems 41 | # 42 | # The first line in each type will be used as defaults for resolver arguments and 43 | # modelgen, the others will be allowed when binding to fields. Configure them to 44 | # your liking 45 | models: 46 | ID: 47 | model: 48 | - github.com/99designs/gqlgen/graphql.ID 49 | - github.com/99designs/gqlgen/graphql.Int 50 | - github.com/99designs/gqlgen/graphql.Int64 51 | - github.com/99designs/gqlgen/graphql.Int32 52 | Int: 53 | model: 54 | - github.com/99designs/gqlgen/graphql.Int 55 | - github.com/99designs/gqlgen/graphql.Int64 56 | - github.com/99designs/gqlgen/graphql.Int32 57 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | --- 2 | title: ‌Introduction To GraphQL Server With Golang 3 | published: false 4 | description: Introduction to GraphQL Server with Golang and Gqlgen. 5 | tags: graphql, go, api, gqlgen 6 | --- 7 | ## Table Of Contents 8 | - [Table Of Contents](#table-of-contents) 9 | - [How to Run The Project](#how-to-run-project) 10 | - [Motivation ](#motivation) 11 | - [What is a GraphQL server?](#what-is-a-graphql-server) 12 | - [Schema-Driven Development](#schema-driven-development) 13 | - [Getting started ](#getting-started) 14 | - [Project Setup](#project-setup) 15 | - [Defining Our Schema](#defining-out-schema) 16 | - [Queries](#queries) 17 | - [What Is A Query](#what-is-a-query) 18 | - [Simple Query](#simple-query) 19 | - [Mutations](#mutations) 20 | - [What Is A Mutation](#what-is-a-mutation) 21 | - [A Simple Mutation](#a-simple-mutation) 22 | - [Database](#database) 23 | - [Setup MySQL](#setup-mysql) 24 | - [Models and migrations](#models-and-migrations) 25 | - [Create and Retrieve Links](#create-and-retrieve-links) 26 | - [CreateLinks](#createlinks) 27 | - [Links Query](#links-query) 28 | - [Authentication](#authentication) 29 | - [JWT](#jwt) 30 | - [Setup](#setup) 31 | - [Generating and Parsing JWT Tokens](#generating-and-parsing-jwt-tokens) 32 | - [User Signup and Login Functionality](#user-signup-and-login-functionality) 33 | - [Authentication Middleware](#authentication-middleware) 34 | - [Continue Implementing schema](#continue-implementing-schema) 35 | - [CreateUser](#createuser) 36 | - [Login](#login) 37 | - [RefreshToken](#refresh-token) 38 | - [Completing Our App](#completing-our-app) 39 | - [Summary](#summary) 40 | - [Further Steps](#further-steps) 41 | 42 | 43 | ### How to Run The Project 44 | First start mysql server with docker: 45 | ```bash 46 | docker run -p 3306:3306 --name mysql -e MYSQL_ROOT_PASSWORD=dbpass -e MYSQL_DATABASE=hackernews -d mysql:latest 47 | ``` 48 | Then create a Table names hackernews for our app: 49 | ```sql 50 | docker exec -it mysql bash 51 | mysql -u root -p 52 | CREATE DATABASE hackernews; 53 | ``` 54 | finally run the server: 55 | ```bash 56 | go run server/server.go 57 | ``` 58 | Now navigate to https://localhost:8080 you can see graphiql playground and query the graphql server. 59 | 60 | 61 | ### Tutorial 62 | to see the latest version of tutorial visit https://www.howtographql.com/graphql-go/0-introduction/ 63 | -------------------------------------------------------------------------------- /internal/users/users.go: -------------------------------------------------------------------------------- 1 | package users 2 | 3 | import ( 4 | "database/sql" 5 | "github.com/glyphack/graphlq-golang/internal/pkg/db/mysql" 6 | "golang.org/x/crypto/bcrypt" 7 | "log" 8 | ) 9 | 10 | type User struct { 11 | ID string `json:"id"` 12 | Username string `json:"name"` 13 | Password string `json:"password"` 14 | } 15 | 16 | func (user *User) Create() { 17 | statement, err := database.Db.Prepare("INSERT INTO Users(Username,Password) VALUES(?,?)") 18 | print(statement) 19 | if err != nil { 20 | log.Fatal(err) 21 | } 22 | hashedPassword, err := HashPassword(user.Password) 23 | _, err = statement.Exec(user.Username, hashedPassword) 24 | if err != nil { 25 | log.Fatal(err) 26 | } 27 | } 28 | 29 | func (user *User) Authenticate() bool { 30 | statement, err := database.Db.Prepare("select Password from Users WHERE Username = ?") 31 | if err != nil { 32 | log.Fatal(err) 33 | } 34 | row := statement.QueryRow(user.Username) 35 | 36 | var hashedPassword string 37 | err = row.Scan(&hashedPassword) 38 | if err != nil { 39 | if err == sql.ErrNoRows { 40 | return false 41 | } else { 42 | log.Fatal(err) 43 | } 44 | } 45 | 46 | return CheckPasswordHash(user.Password, hashedPassword) 47 | } 48 | 49 | //GetUserIdByUsername check if a user exists in database by given username 50 | func GetUserIdByUsername(username string) (int, error) { 51 | statement, err := database.Db.Prepare("select ID from Users WHERE Username = ?") 52 | if err != nil { 53 | log.Fatal(err) 54 | } 55 | row := statement.QueryRow(username) 56 | 57 | var Id int 58 | err = row.Scan(&Id) 59 | if err != nil { 60 | if err != sql.ErrNoRows { 61 | log.Print(err) 62 | } 63 | return 0, err 64 | } 65 | 66 | return Id, nil 67 | } 68 | 69 | //GetUserByID check if a user exists in database and return the user object. 70 | func GetUsernameById(userId string) (User, error) { 71 | statement, err := database.Db.Prepare("select Username from Users WHERE ID = ?") 72 | if err != nil { 73 | log.Fatal(err) 74 | } 75 | row := statement.QueryRow(userId) 76 | 77 | var username string 78 | err = row.Scan(&username) 79 | if err != nil { 80 | if err != sql.ErrNoRows { 81 | log.Print(err) 82 | } 83 | return User{}, err 84 | } 85 | 86 | return User{ID: userId, Username: username}, nil 87 | } 88 | 89 | //HashPassword hashes given password 90 | func HashPassword(password string) (string, error) { 91 | bytes, err := bcrypt.GenerateFromPassword([]byte(password), 14) 92 | return string(bytes), err 93 | } 94 | 95 | //CheckPassword hash compares raw password with it's hashed values 96 | func CheckPasswordHash(password, hash string) bool { 97 | err := bcrypt.CompareHashAndPassword([]byte(hash), []byte(password)) 98 | return err == nil 99 | } 100 | -------------------------------------------------------------------------------- /graph/schema.resolvers.go: -------------------------------------------------------------------------------- 1 | package graph 2 | 3 | // This file will be automatically regenerated based on the schema, any resolver implementations 4 | // will be copied through when generating and any unknown code will be moved to the end. 5 | 6 | import ( 7 | "context" 8 | "fmt" 9 | "strconv" 10 | 11 | "github.com/glyphack/graphlq-golang/graph/generated" 12 | "github.com/glyphack/graphlq-golang/graph/model" 13 | "github.com/glyphack/graphlq-golang/internal/auth" 14 | "github.com/glyphack/graphlq-golang/internal/links" 15 | "github.com/glyphack/graphlq-golang/internal/users" 16 | "github.com/glyphack/graphlq-golang/pkg/jwt" 17 | ) 18 | 19 | func (r *mutationResolver) CreateLink(ctx context.Context, input model.NewLink) (*model.Link, error) { 20 | user := auth.ForContext(ctx) 21 | if user == nil { 22 | return &model.Link{}, fmt.Errorf("access denied") 23 | } 24 | var link links.Link 25 | link.Title = input.Title 26 | link.Address = input.Address 27 | link.User = user 28 | linkId := link.Save() 29 | grahpqlUser := &model.User{ 30 | ID: user.ID, 31 | Name: user.Username, 32 | } 33 | return &model.Link{ID: strconv.FormatInt(linkId, 10), Title: link.Title, Address: link.Address, User: grahpqlUser}, nil 34 | } 35 | 36 | func (r *mutationResolver) CreateUser(ctx context.Context, input model.NewUser) (string, error) { 37 | var user users.User 38 | user.Username = input.Username 39 | user.Password = input.Password 40 | user.Create() 41 | token, err := jwt.GenerateToken(user.Username) 42 | if err != nil { 43 | return "", err 44 | } 45 | return token, nil 46 | } 47 | 48 | func (r *mutationResolver) Login(ctx context.Context, input model.Login) (string, error) { 49 | var user users.User 50 | user.Username = input.Username 51 | user.Password = input.Password 52 | correct := user.Authenticate() 53 | if !correct { 54 | // 1 55 | return "", &users.WrongUsernameOrPasswordError{} 56 | } 57 | token, err := jwt.GenerateToken(user.Username) 58 | if err != nil { 59 | return "", err 60 | } 61 | return token, nil 62 | } 63 | 64 | func (r *mutationResolver) RefreshToken(ctx context.Context, input model.RefreshTokenInput) (string, error) { 65 | username, err := jwt.ParseToken(input.Token) 66 | if err != nil { 67 | return "", fmt.Errorf("access denied") 68 | } 69 | token, err := jwt.GenerateToken(username) 70 | if err != nil { 71 | return "", err 72 | } 73 | return token, nil 74 | } 75 | 76 | func (r *queryResolver) Links(ctx context.Context) ([]*model.Link, error) { 77 | var resultLinks []*model.Link 78 | var dbLinks []links.Link 79 | dbLinks = links.GetAll() 80 | for _, link := range dbLinks { 81 | grahpqlUser := &model.User{ 82 | Name: link.User.Password, 83 | } 84 | resultLinks = append(resultLinks, &model.Link{ID: link.ID, Title: link.Title, Address: link.Address, User: grahpqlUser}) 85 | } 86 | return resultLinks, nil 87 | } 88 | 89 | // Mutation returns generated.MutationResolver implementation. 90 | func (r *Resolver) Mutation() generated.MutationResolver { return &mutationResolver{r} } 91 | 92 | // Query returns generated.QueryResolver implementation. 93 | func (r *Resolver) Query() generated.QueryResolver { return &queryResolver{r} } 94 | 95 | type mutationResolver struct{ *Resolver } 96 | type queryResolver struct{ *Resolver } 97 | -------------------------------------------------------------------------------- /go.sum: -------------------------------------------------------------------------------- 1 | cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= 2 | cloud.google.com/go v0.34.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw= 3 | cloud.google.com/go v0.38.0/go.mod h1:990N+gfupTy94rShfmMCWGDn0LpTmnzTp2qbd1dvSRU= 4 | cloud.google.com/go v0.44.1/go.mod h1:iSa0KzasP4Uvy3f1mN/7PiObzGgflwredwwASm/v6AU= 5 | cloud.google.com/go v0.44.2/go.mod h1:60680Gw3Yr4ikxnPRS/oxxkBccT6SA1yMk63TGekxKY= 6 | cloud.google.com/go v0.45.1/go.mod h1:RpBamKRgapWJb87xiFSdk4g1CME7QZg3uwTez+TSTjc= 7 | cloud.google.com/go v0.46.3/go.mod h1:a6bKKbmY7er1mI7TEI4lsAkts/mkhTSZK8w33B4RAg0= 8 | cloud.google.com/go v0.50.0/go.mod h1:r9sluTvynVuxRIOHXQEHMFffphuXHOMZMycpNR5e6To= 9 | cloud.google.com/go v0.52.0/go.mod h1:pXajvRH/6o3+F9jDHZWQ5PbGhn+o8w9qiu/CffaVdO4= 10 | cloud.google.com/go v0.53.0/go.mod h1:fp/UouUEsRkN6ryDKNW/Upv/JBKnv6WDthjR6+vze6M= 11 | cloud.google.com/go v0.54.0/go.mod h1:1rq2OEkV3YMf6n/9ZvGWI3GWw0VoqH/1x2nd8Is/bPc= 12 | cloud.google.com/go v0.56.0/go.mod h1:jr7tqZxxKOVYizybht9+26Z/gUq7tiRzu+ACVAMbKVk= 13 | cloud.google.com/go v0.57.0/go.mod h1:oXiQ6Rzq3RAkkY7N6t3TcE6jE+CIBBbA36lwQ1JyzZs= 14 | cloud.google.com/go v0.60.0/go.mod h1:yw2G51M9IfRboUH61Us8GqCeF1PzPblB823Mn2q2eAU= 15 | cloud.google.com/go v0.61.0/go.mod h1:XukKJg4Y7QsUu0Hxg3qQKUWR4VuWivmyMK2+rUyxAqw= 16 | cloud.google.com/go/bigquery v1.0.1/go.mod h1:i/xbL2UlR5RvWAURpBYZTtm/cXjCha9lbfbpx4poX+o= 17 | cloud.google.com/go/bigquery v1.3.0/go.mod h1:PjpwJnslEMmckchkHFfq+HTD2DmtT67aNFKH1/VBDHE= 18 | cloud.google.com/go/bigquery v1.4.0/go.mod h1:S8dzgnTigyfTmLBfrtrhyYhwRxG72rYxvftPBK2Dvzc= 19 | cloud.google.com/go/bigquery v1.5.0/go.mod h1:snEHRnqQbz117VIFhE8bmtwIDY80NLUZUMb4Nv6dBIg= 20 | cloud.google.com/go/bigquery v1.7.0/go.mod h1://okPTzCYNXSlb24MZs83e2Do+h+VXtc4gLoIoXIAPc= 21 | cloud.google.com/go/bigquery v1.8.0/go.mod h1:J5hqkt3O0uAFnINi6JXValWIb1v0goeZM77hZzJN/fQ= 22 | cloud.google.com/go/datastore v1.0.0/go.mod h1:LXYbyblFSglQ5pkeyhO+Qmw7ukd3C+pD7TKLgZqpHYE= 23 | cloud.google.com/go/datastore v1.1.0/go.mod h1:umbIZjpQpHh4hmRpGhH4tLFup+FVzqBi1b3c64qFpCk= 24 | cloud.google.com/go/pubsub v1.0.1/go.mod h1:R0Gpsv3s54REJCy4fxDixWD93lHJMoZTyQ2kNxGRt3I= 25 | cloud.google.com/go/pubsub v1.1.0/go.mod h1:EwwdRX2sKPjnvnqCa270oGRyludottCI76h+R3AArQw= 26 | cloud.google.com/go/pubsub v1.2.0/go.mod h1:jhfEVHT8odbXTkndysNHCcx0awwzvfOlguIAii9o8iA= 27 | cloud.google.com/go/pubsub v1.3.1/go.mod h1:i+ucay31+CNRpDW4Lu78I4xXG+O1r/MAHgjpRVR+TSU= 28 | cloud.google.com/go/spanner v1.8.0/go.mod h1:mdAPDiFUbE9vCmhHHlxyDUtaPPsIK+pUdf5KmHaUfT8= 29 | cloud.google.com/go/storage v1.0.0/go.mod h1:IhtSnM/ZTZV8YYJWCY8RULGVqBDmpoyjwiyrjsg+URw= 30 | cloud.google.com/go/storage v1.5.0/go.mod h1:tpKbwo567HUNpVclU5sGELwQWBDZ8gh0ZeosJ0Rtdos= 31 | cloud.google.com/go/storage v1.6.0/go.mod h1:N7U0C8pVQ/+NIKOBQyamJIeKQKkZ+mxpohlUTyfDhBk= 32 | cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RXyy7KQOVs= 33 | cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0= 34 | dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= 35 | github.com/99designs/gqlgen v0.10.2 h1:FfjCqIWejHDJeLpQTI0neoZo5vDO3sdo5oNCucet3A0= 36 | github.com/99designs/gqlgen v0.10.2/go.mod h1:aDB7oabSAyZ4kUHLEySsLxnWrBy3lA0A2gWKU+qoHwI= 37 | github.com/99designs/gqlgen v0.11.3 h1:oFSxl1DFS9X///uHV3y6CEfpcXWrDUxVblR4Xib2bs4= 38 | github.com/99designs/gqlgen v0.11.3/go.mod h1:RgX5GRRdDWNkh4pBrdzNpNPFVsdoUFY2+adM6nb1N+4= 39 | github.com/Azure/go-ansiterm v0.0.0-20170929234023-d6e3b3328b78/go.mod h1:LmzpDX56iTiv29bbRTIsUNlaFfuhWRQBWjQdVyAevI8= 40 | github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= 41 | github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= 42 | github.com/ClickHouse/clickhouse-go v1.3.12/go.mod h1:EaI/sW7Azgz9UATzd5ZdZHRUhHgv5+JMS9NSr2smCJI= 43 | github.com/Microsoft/go-winio v0.4.11/go.mod h1:VhR8bwka0BXejwEJY73c50VrPtXAaKcyvVC4A4RozmA= 44 | github.com/Microsoft/go-winio v0.4.14 h1:+hMXMk01us9KgxGb7ftKQt2Xpf5hH/yky+TDA+qxleU= 45 | github.com/Microsoft/go-winio v0.4.14/go.mod h1:qXqCSQ3Xa7+6tgxaGTIe4Kpcdsi+P8jBhyzoq1bpyYA= 46 | github.com/agnivade/levenshtein v1.0.1 h1:3oJU7J3FGFmyhn8KHjmVaZCN5hxTr7GxgRue+sxIXdQ= 47 | github.com/agnivade/levenshtein v1.0.1/go.mod h1:CURSv5d9Uaml+FovSIICkLbAUZ9S4RqaHDIsdSBg7lM= 48 | github.com/agnivade/levenshtein v1.0.3 h1:M5ZnqLOoZR8ygVq0FfkXsNOKzMCk0xRiow0R5+5VkQ0= 49 | github.com/agnivade/levenshtein v1.0.3/go.mod h1:4SFRZbbXWLF4MU1T9Qg0pGgH3Pjs+t6ie5efyrwRJXs= 50 | github.com/andreyvit/diff v0.0.0-20170406064948-c7f18ee00883 h1:bvNMNQO63//z+xNgfBlViaCIJKLlCJ6/fmUseuG0wVQ= 51 | github.com/andreyvit/diff v0.0.0-20170406064948-c7f18ee00883/go.mod h1:rCTlJbsFo29Kk6CurOXKm700vrz8f0KW0JNfpkRJY/8= 52 | github.com/apache/arrow/go/arrow v0.0.0-20200601151325-b2287a20f230/go.mod h1:QNYViu/X0HXDHw7m3KXzWSVXIbfUvJqBFe6Gj8/pYA0= 53 | github.com/arbovm/levenshtein v0.0.0-20160628152529-48b4e1c0c4d0 h1:jfIu9sQUG6Ig+0+Ap1h4unLjW6YQJpKZVmUzxsD4E/Q= 54 | github.com/arbovm/levenshtein v0.0.0-20160628152529-48b4e1c0c4d0/go.mod h1:t2tdKJDJF9BV14lnkjHmOQgcvEKgtqs5a1N3LNdJhGE= 55 | github.com/aws/aws-sdk-go v1.17.7/go.mod h1:KmX6BPdI08NWTb3/sm4ZGu5ShLoqVDhKgpiN924inxo= 56 | github.com/bitly/go-hostpool v0.0.0-20171023180738-a3a6125de932/go.mod h1:NOuUCSz6Q9T7+igc/hlvDOUdtWKryOrtFyIVABv/p7k= 57 | github.com/bkaradzic/go-lz4 v1.0.0/go.mod h1:0YdlkowM3VswSROI7qDxhRvJ3sLhlFrRRwjwegp5jy4= 58 | github.com/bmizerany/assert v0.0.0-20160611221934-b7ed37b82869/go.mod h1:Ekp36dRnpXw/yCqJaO+ZrUyxD+3VXMFFr56k5XYrpB4= 59 | github.com/census-instrumentation/opencensus-proto v0.2.1/go.mod h1:f6KPmirojxKA12rnyqOA5BBL4O983OfeGPqjHWSTneU= 60 | github.com/chzyer/logex v1.1.10/go.mod h1:+Ywpsq7O8HXn0nuIou7OrIPyXbp3wmkHB+jjWRnGsAI= 61 | github.com/chzyer/readline v0.0.0-20180603132655-2972be24d48e/go.mod h1:nSuG5e5PlCu98SY8svDHJxuZscDgtXS6KTTbou5AhLI= 62 | github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1/go.mod h1:Q3SI9o4m/ZMnBNeIyt5eFwwo7qiLfzFZmjNmxjkiQlU= 63 | github.com/client9/misspell v0.3.4/go.mod h1:qj6jICC3Q7zFZvVWo7KLAzC3yx5G7kyvSDkc90ppPyw= 64 | github.com/cloudflare/golz4 v0.0.0-20150217214814-ef862a3cdc58/go.mod h1:EOBUe0h4xcZ5GoxqC5SDxFQ8gwyZPKQoEzownBlhI80= 65 | github.com/cncf/udpa/go v0.0.0-20191209042840-269d4d468f6f/go.mod h1:M8M6+tZqaGXZJjfX53e64911xZQV5JYwmTeXPW+k8Sc= 66 | github.com/cockroachdb/apd v1.1.0/go.mod h1:8Sl8LxpKi29FqWXR16WEFZRNSz3SoPzUzeMeY4+DwBQ= 67 | github.com/cockroachdb/cockroach-go v0.0.0-20190925194419-606b3d062051/go.mod h1:XGLbWH/ujMcbPbhZq52Nv6UrCghb1yGn//133kEsvDk= 68 | github.com/containerd/containerd v1.3.3/go.mod h1:bC6axHOhabU15QhwfG7w5PipXdVtMXFTttgp+kVtyUA= 69 | github.com/coreos/go-systemd v0.0.0-20190321100706-95778dfbb74e/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= 70 | github.com/coreos/go-systemd v0.0.0-20190719114852-fd7a80b32e1f/go.mod h1:F5haX7vjVVG0kc13fIWeqUViNPyEJxv/OmvnBo0Yme4= 71 | github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d h1:U+s90UTSYgptZMwQh2aRr3LuazLJIa+Pg3Kc1ylSYVY= 72 | github.com/cpuguy83/go-md2man/v2 v2.0.0-20190314233015-f79a8a8ca69d/go.mod h1:maD7wRr/U5Z6m/iR4s+kqSMx2CaBsrgA7czyZG/E6dU= 73 | github.com/creack/pty v1.1.7/go.mod h1:lj5s0c3V2DBrqTV7llrYr5NG6My20zk30Fl46Y7DoTY= 74 | github.com/cznic/mathutil v0.0.0-20180504122225-ca4c9f2c1369/go.mod h1:e6NPNENfs9mPDVNRekM7lKScauxd5kXTr1Mfyig6TDM= 75 | github.com/davecgh/go-spew v1.1.0/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= 76 | github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= 77 | github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= 78 | github.com/denisenkom/go-mssqldb v0.0.0-20200620013148-b91950f658ec/go.mod h1:xbL0rPBG9cCiLr28tMa8zpbdarY27NDyej4t/EjAShU= 79 | github.com/dgrijalva/jwt-go v3.2.0+incompatible h1:7qlOGliEKZXTDg6OTjfoBKDXWrumCAMpl/TFQ4/5kLM= 80 | github.com/dgrijalva/jwt-go v3.2.0+incompatible/go.mod h1:E3ru+11k8xSBh+hMPgOLZmtrrCbhqsmaPHjLKYnJCaQ= 81 | github.com/dgryski/trifles v0.0.0-20190318185328-a8d75aae118c h1:TUuUh0Xgj97tLMNtWtNvI9mIV6isjEb9lBMNv+77IGM= 82 | github.com/dgryski/trifles v0.0.0-20190318185328-a8d75aae118c/go.mod h1:if7Fbed8SFyPtHLHbg49SI7NAdJiC5WIA09pe59rfAA= 83 | github.com/dhui/dktest v0.3.2/go.mod h1:l1/ib23a/CmxAe7yixtrYPc8Iy90Zy2udyaHINM5p58= 84 | github.com/docker/distribution v2.7.0+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= 85 | github.com/docker/distribution v2.7.1+incompatible h1:a5mlkVzth6W5A4fOsS3D2EO5BUmsJpcB+cRlLU7cSug= 86 | github.com/docker/distribution v2.7.1+incompatible/go.mod h1:J2gT2udsDAN96Uj4KfcMRqY0/ypR+oyYUYmja8H+y+w= 87 | github.com/docker/docker v1.4.2-0.20200213202729-31a86c4ab209/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= 88 | github.com/docker/docker v1.13.1 h1:IkZjBSIc8hBjLpqeAbeE5mca5mNgeatLHBy3GO78BWo= 89 | github.com/docker/docker v1.13.1/go.mod h1:eEKB0N0r5NX/I1kEveEz05bcu8tLC/8azJZsviup8Sk= 90 | github.com/docker/go-connections v0.4.0 h1:El9xVISelRB7BuFusrZozjnkIM5YnzCViNKohAFqRJQ= 91 | github.com/docker/go-connections v0.4.0/go.mod h1:Gbd7IOopHjR8Iph03tsViu4nIes5XhDvyHbTtUxmeec= 92 | github.com/docker/go-units v0.3.3/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= 93 | github.com/docker/go-units v0.4.0 h1:3uh0PgVws3nIA0Q+MwDC8yjEPf9zjRfZZWXZYDct3Tw= 94 | github.com/docker/go-units v0.4.0/go.mod h1:fgPhTUdO+D/Jk86RDLlptpiXQzgHJF7gydDDbaIK4Dk= 95 | github.com/edsrzf/mmap-go v0.0.0-20170320065105-0bce6a688712/go.mod h1:YO35OhQPt3KJa3ryjFM5Bs14WD66h8eGKpfaBNrHW5M= 96 | github.com/envoyproxy/go-control-plane v0.9.0/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= 97 | github.com/envoyproxy/go-control-plane v0.9.1-0.20191026205805-5f8ba28d4473/go.mod h1:YTl/9mNaCwkRvm6d1a2C3ymFceY/DCBVvsKhRF0iEA4= 98 | github.com/envoyproxy/go-control-plane v0.9.4/go.mod h1:6rpuAdCZL397s3pYoYcLgu1mIlRU8Am5FuJP05cCM98= 99 | github.com/envoyproxy/protoc-gen-validate v0.1.0/go.mod h1:iSmxcyjqTsJpI2R4NaDN7+kN2VEUnK/pcBlmesArF7c= 100 | github.com/fsnotify/fsnotify v1.4.7/go.mod h1:jwhsz4b93w/PPRr/qN1Yymfu8t87LnFCMoQvtojpjFo= 101 | github.com/fsouza/fake-gcs-server v1.17.0/go.mod h1:D1rTE4YCyHFNa99oyJJ5HyclvN/0uQR+pM/VdlL83bw= 102 | github.com/glyphack/graphql-golang v0.0.0-20200522081210-00d36dcf3663 h1:z9SNxPrFJ7HXOob3tAdvb91llyEWF15tH6IYuFdL4EQ= 103 | github.com/go-chi/chi v3.3.2+incompatible h1:uQNcQN3NsV1j4ANsPh42P4ew4t6rnRbJb8frvpp31qQ= 104 | github.com/go-chi/chi v3.3.2+incompatible/go.mod h1:eB3wogJHnLi3x/kFX2A+IbTBlXxmMeXJVKy9tTv1XzQ= 105 | github.com/go-gl/glfw v0.0.0-20190409004039-e6da0acd62b1/go.mod h1:vR7hzQXu2zJy9AVAgeJqvqgH9Q5CA+iKCZ2gyEVpxRU= 106 | github.com/go-gl/glfw/v3.3/glfw v0.0.0-20191125211704-12ad95a8df72/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= 107 | github.com/go-gl/glfw/v3.3/glfw v0.0.0-20200222043503-6f7a984d4dc4/go.mod h1:tQ2UAYgL5IevRw8kRxooKSPJfGvJ9fJQFa0TUsXzTg8= 108 | github.com/go-sql-driver/mysql v1.4.0/go.mod h1:zAC/RDZ24gD3HViQzih4MyKcchzm+sOG5ZlKdlhCg5w= 109 | github.com/go-sql-driver/mysql v1.5.0 h1:ozyZYNQW3x3HtqT1jira07DN2PArx2v7/mN66gGcHOs= 110 | github.com/go-sql-driver/mysql v1.5.0/go.mod h1:DCzpHaOWr8IXmIStZouvnhqoel9Qv2LBy8hT2VhHyBg= 111 | github.com/go-stack/stack v1.8.0/go.mod h1:v0f6uXyyMGvRgIKkXu+yp6POWl0qKG85gN/melR3HDY= 112 | github.com/gobuffalo/here v0.6.0/go.mod h1:wAG085dHOYqUpf+Ap+WOdrPTp5IYcDAs/x7PLa8Y5fM= 113 | github.com/gocql/gocql v0.0.0-20190301043612-f6df8288f9b4/go.mod h1:4Fw1eo5iaEhDUs8XyuhSVCVy52Jq3L+/3GJgYkwc+/0= 114 | github.com/gogo/protobuf v1.0.0/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= 115 | github.com/gogo/protobuf v1.2.0/go.mod h1:r8qH/GZQm5c6nD/R0oafs1akxWv10x8SbQlK7atdtwQ= 116 | github.com/gogo/protobuf v1.3.1/go.mod h1:SlYgWuQ5SjCEi6WLHjHCa1yvBfUnHcTbrrZtXPKa29o= 117 | github.com/golang-migrate/migrate v3.5.4+incompatible h1:R7OzwvCJTCgwapPCiX6DyBiu2czIUMDCB118gFTKTUA= 118 | github.com/golang-migrate/migrate v3.5.4+incompatible/go.mod h1:IsVUlFN5puWOmXrqjgGUfIRIbU7mr8oNBE2tyERd9Wk= 119 | github.com/golang-migrate/migrate/v4 v4.12.2 h1:QI43Tlouiwpp2dK5Y767OouX0snJNRP/NubsVaArzDU= 120 | github.com/golang-migrate/migrate/v4 v4.12.2/go.mod h1:HQ1DaC8uLHkg4afY8ZQ8D/P5SG+YW9X5INZBVvm+d2k= 121 | github.com/golang-sql/civil v0.0.0-20190719163853-cb61b32ac6fe/go.mod h1:8vg3r2VgvsThLBIFL93Qb5yWzgyZWhEmBwUJWevAkK0= 122 | github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q= 123 | github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= 124 | github.com/golang/groupcache v0.0.0-20191227052852-215e87163ea7/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= 125 | github.com/golang/groupcache v0.0.0-20200121045136-8c9f03a8e57e/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc= 126 | github.com/golang/mock v1.1.1/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= 127 | github.com/golang/mock v1.2.0/go.mod h1:oTYuIxOrZwtPieC+H1uAHpcLFnEyAGVDL/k47Jfbm0A= 128 | github.com/golang/mock v1.3.1/go.mod h1:sBzyDLLjw3U8JLTeZvSv8jJB+tU5PVekmnlKIyFUx0Y= 129 | github.com/golang/mock v1.4.0/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw= 130 | github.com/golang/mock v1.4.1/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw= 131 | github.com/golang/mock v1.4.3/go.mod h1:UOMv5ysSaYNkG+OFQykRIcU/QvvxJf3p21QfJ2Bt3cw= 132 | github.com/golang/protobuf v1.2.0/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= 133 | github.com/golang/protobuf v1.3.1/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= 134 | github.com/golang/protobuf v1.3.2/go.mod h1:6lQm79b+lXiMfvg/cZm0SGofjICqVBUtrP5yJMmIC1U= 135 | github.com/golang/protobuf v1.3.3/go.mod h1:vzj43D7+SQXF/4pzW/hwtAqwc6iTitCiVSaWz5lYuqw= 136 | github.com/golang/protobuf v1.3.4/go.mod h1:vzj43D7+SQXF/4pzW/hwtAqwc6iTitCiVSaWz5lYuqw= 137 | github.com/golang/protobuf v1.3.5/go.mod h1:6O5/vntMXwX2lRkT1hjjk0nAC1IDOTvTlVgjlRvqsdk= 138 | github.com/golang/protobuf v1.4.0-rc.1/go.mod h1:ceaxUfeHdC40wWswd/P6IGgMaK3YpKi5j83Wpe3EHw8= 139 | github.com/golang/protobuf v1.4.0-rc.1.0.20200221234624-67d41d38c208/go.mod h1:xKAWHe0F5eneWXFV3EuXVDTCmh+JuBKY0li0aMyXATA= 140 | github.com/golang/protobuf v1.4.0-rc.2/go.mod h1:LlEzMj4AhA7rCAGe4KMBDvJI+AwstrUpVNzEA03Pprs= 141 | github.com/golang/protobuf v1.4.0-rc.4.0.20200313231945-b860323f09d0/go.mod h1:WU3c8KckQ9AFe+yFwt9sWVRKCVIyN9cPHBJSNnbL67w= 142 | github.com/golang/protobuf v1.4.0/go.mod h1:jodUvKwWbYaEsadDk5Fwe5c77LiNKVO9IDvqG2KuDX0= 143 | github.com/golang/protobuf v1.4.1/go.mod h1:U8fpvMrcmy5pZrNK1lt4xCsGvpyWQ/VVv6QDs8UjoX8= 144 | github.com/golang/protobuf v1.4.2/go.mod h1:oDoupMAO8OvCJWAcko0GGGIgR6R6ocIYbsSw735rRwI= 145 | github.com/golang/snappy v0.0.0-20170215233205-553a64147049/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= 146 | github.com/golang/snappy v0.0.1/go.mod h1:/XxbfmMg8lxefKM7IXC3fBNl/7bRcc72aCRzEWrmP2Q= 147 | github.com/google/btree v0.0.0-20180813153112-4030bb1f1f0c/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= 148 | github.com/google/btree v1.0.0/go.mod h1:lNA+9X1NB3Zf8V7Ke586lFgjr2dZNuvo3lPJSGZ5JPQ= 149 | github.com/google/flatbuffers v1.11.0/go.mod h1:1AeVuKshWv4vARoZatz6mlQ0JxURH0Kv5+zNeJKJCa8= 150 | github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M= 151 | github.com/google/go-cmp v0.3.0/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= 152 | github.com/google/go-cmp v0.3.1/go.mod h1:8QqcDgzrUqlUb/G2PQTWiueGozuR1884gddMywk6iLU= 153 | github.com/google/go-cmp v0.4.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= 154 | github.com/google/go-cmp v0.4.1/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= 155 | github.com/google/go-cmp v0.5.0/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= 156 | github.com/google/go-cmp v0.5.1/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/gNBxE= 157 | github.com/google/go-github v17.0.0+incompatible/go.mod h1:zLgOLi98H3fifZn+44m+umXrS52loVEgC2AApnigrVQ= 158 | github.com/google/go-querystring v1.0.0/go.mod h1:odCYkC5MyYFN7vkCjXpyrEuKhc/BUO6wN/zVPAxq5ck= 159 | github.com/google/martian v2.1.0+incompatible/go.mod h1:9I4somxYTbIHy5NJKHRl3wXiIaQGbYVAs8BPL6v8lEs= 160 | github.com/google/martian/v3 v3.0.0/go.mod h1:y5Zk1BBys9G+gd6Jrk0W3cC1+ELVxBWuIGO+w/tUAp0= 161 | github.com/google/pprof v0.0.0-20181206194817-3ea8567a2e57/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc= 162 | github.com/google/pprof v0.0.0-20190515194954-54271f7e092f/go.mod h1:zfwlbNMJ+OItoe0UupaVj+oy1omPYYDuagoSzA8v9mc= 163 | github.com/google/pprof v0.0.0-20191218002539-d4f498aebedc/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM= 164 | github.com/google/pprof v0.0.0-20200212024743-f11f1df84d12/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM= 165 | github.com/google/pprof v0.0.0-20200229191704-1ebb73c60ed3/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM= 166 | github.com/google/pprof v0.0.0-20200430221834-fc25d7d30c6d/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM= 167 | github.com/google/pprof v0.0.0-20200507031123-427632fa3b1c/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM= 168 | github.com/google/pprof v0.0.0-20200708004538-1a94d8640e99/go.mod h1:ZgVRPoUq/hfqzAqh7sHMqb3I9Rq5C59dIz2SbBwJ4eM= 169 | github.com/google/renameio v0.1.0/go.mod h1:KWCgfxg9yswjAJkECMjeO8J8rahYeXnNhOm40UhjYkI= 170 | github.com/google/uuid v1.1.1/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo= 171 | github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= 172 | github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= 173 | github.com/gorilla/context v0.0.0-20160226214623-1ea25387ff6f/go.mod h1:kBGZzfjB9CEq2AlWe17Uuf7NDRt0dE0s8S51q0aT7Yg= 174 | github.com/gorilla/context v1.1.1/go.mod h1:kBGZzfjB9CEq2AlWe17Uuf7NDRt0dE0s8S51q0aT7Yg= 175 | github.com/gorilla/handlers v1.4.2/go.mod h1:Qkdc/uu4tH4g6mTK6auzZ766c4CA0Ng8+o/OAirnOIQ= 176 | github.com/gorilla/mux v1.6.1/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs= 177 | github.com/gorilla/mux v1.6.2/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs= 178 | github.com/gorilla/mux v1.7.3/go.mod h1:1lud6UwP+6orDFRuTfBEV8e9/aOM/c4fVVCaMa2zaAs= 179 | github.com/gorilla/mux v1.7.4/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So= 180 | github.com/gorilla/websocket v1.2.0 h1:VJtLvh6VQym50czpZzx07z/kw9EgAxI3x1ZB8taTMQQ= 181 | github.com/gorilla/websocket v1.2.0/go.mod h1:E7qHFY5m1UJ88s3WnNqhKjPHQ0heANvMoAMk2YaljkQ= 182 | github.com/hailocab/go-hostpool v0.0.0-20160125115350-e80d13ce29ed/go.mod h1:tMWxXQ9wFIaZeTI9F+hmhFiGpFmhOHzyShyFUhRm0H4= 183 | github.com/hashicorp/errwrap v1.0.0 h1:hLrqtEDnRye3+sgx6z4qVLNuviH3MR5aQ0ykNJa/UYA= 184 | github.com/hashicorp/errwrap v1.0.0/go.mod h1:YH+1FKiLXxHSkmPseP+kNlulaMuP3n2brvKWEqk/Jc4= 185 | github.com/hashicorp/go-multierror v1.1.0 h1:B9UzwGQJehnUY1yNrnwREHc3fGbC2xefo8g4TbElacI= 186 | github.com/hashicorp/go-multierror v1.1.0/go.mod h1:spPvp8C1qA32ftKqdAHm4hHTbPw+vmowP0z+KUhOZdA= 187 | github.com/hashicorp/golang-lru v0.5.0 h1:CL2msUPvZTLb5O648aiLNJw3hnBxN2+1Jq8rCOH9wdo= 188 | github.com/hashicorp/golang-lru v0.5.0/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= 189 | github.com/hashicorp/golang-lru v0.5.1 h1:0hERBMJE1eitiLkihrMvRVBYAkpHzc/J3QdDN+dAcgU= 190 | github.com/hashicorp/golang-lru v0.5.1/go.mod h1:/m3WP610KZHVQ1SGc6re/UDhFvYD7pJ4Ao+sR/qLZy8= 191 | github.com/hpcloud/tail v1.0.0/go.mod h1:ab1qPbhIpdTxEkNHXyeSf5vhxWSCs/tWer42PpOxQnU= 192 | github.com/ianlancetaylor/demangle v0.0.0-20181102032728-5e5cf60278f6/go.mod h1:aSSvb/t6k1mPoxDqO4vJh6VOCGPwU4O0C2/Eqndh1Sc= 193 | github.com/jackc/chunkreader v1.0.0/go.mod h1:RT6O25fNZIuasFJRyZ4R/Y2BbhasbmZXF9QQ7T3kePo= 194 | github.com/jackc/chunkreader/v2 v2.0.0/go.mod h1:odVSm741yZoC3dpHEUXIqA9tQRhFrgOHwnPIn9lDKlk= 195 | github.com/jackc/chunkreader/v2 v2.0.1/go.mod h1:odVSm741yZoC3dpHEUXIqA9tQRhFrgOHwnPIn9lDKlk= 196 | github.com/jackc/pgconn v0.0.0-20190420214824-7e0022ef6ba3/go.mod h1:jkELnwuX+w9qN5YIfX0fl88Ehu4XC3keFuOJJk9pcnA= 197 | github.com/jackc/pgconn v0.0.0-20190824142844-760dd75542eb/go.mod h1:lLjNuW/+OfW9/pnVKPazfWOgNfH2aPem8YQ7ilXGvJE= 198 | github.com/jackc/pgconn v0.0.0-20190831204454-2fabfa3c18b7/go.mod h1:ZJKsE/KZfsUgOEh9hBm+xYTstcNHg7UPMVJqRfQxq4s= 199 | github.com/jackc/pgconn v1.3.2/go.mod h1:LvCquS3HbBKwgl7KbX9KyqEIumJAbm1UMcTvGaIf3bM= 200 | github.com/jackc/pgio v1.0.0/go.mod h1:oP+2QK2wFfUWgr+gxjoBH9KGBb31Eio69xUb0w5bYf8= 201 | github.com/jackc/pgmock v0.0.0-20190831213851-13a1b77aafa2/go.mod h1:fGZlG77KXmcq05nJLRkk0+p82V8B8Dw8KN2/V9c/OAE= 202 | github.com/jackc/pgpassfile v1.0.0/go.mod h1:CEx0iS5ambNFdcRtxPj5JhEz+xB6uRky5eyVu/W2HEg= 203 | github.com/jackc/pgproto3 v1.1.0/go.mod h1:eR5FA3leWg7p9aeAqi37XOTgTIbkABlvcPB3E5rlc78= 204 | github.com/jackc/pgproto3/v2 v2.0.0-alpha1.0.20190420180111-c116219b62db/go.mod h1:bhq50y+xrl9n5mRYyCBFKkpRVTLYJVWeCc+mEAI3yXA= 205 | github.com/jackc/pgproto3/v2 v2.0.0-alpha1.0.20190609003834-432c2951c711/go.mod h1:uH0AWtUmuShn0bcesswc4aBTWGvw0cAxIJp+6OB//Wg= 206 | github.com/jackc/pgproto3/v2 v2.0.0-rc3/go.mod h1:ryONWYqW6dqSg1Lw6vXNMXoBJhpzvWKnT95C46ckYeM= 207 | github.com/jackc/pgproto3/v2 v2.0.0-rc3.0.20190831210041-4c03ce451f29/go.mod h1:ryONWYqW6dqSg1Lw6vXNMXoBJhpzvWKnT95C46ckYeM= 208 | github.com/jackc/pgproto3/v2 v2.0.1/go.mod h1:WfJCnwN3HIg9Ish/j3sgWXnAfK8A9Y0bwXYU5xKaEdA= 209 | github.com/jackc/pgtype v0.0.0-20190421001408-4ed0de4755e0/go.mod h1:hdSHsc1V01CGwFsrv11mJRHWJ6aifDLfdV3aVjFF0zg= 210 | github.com/jackc/pgtype v0.0.0-20190824184912-ab885b375b90/go.mod h1:KcahbBH1nCMSo2DXpzsoWOAfFkdEtEJpPbVLq8eE+mc= 211 | github.com/jackc/pgtype v0.0.0-20190828014616-a8802b16cc59/go.mod h1:MWlu30kVJrUS8lot6TQqcg7mtthZ9T0EoIBFiJcmcyw= 212 | github.com/jackc/pgx/v4 v4.0.0-20190420224344-cc3461e65d96/go.mod h1:mdxmSJJuR08CZQyj1PVQBHy9XOp5p8/SHH6a0psbY9Y= 213 | github.com/jackc/pgx/v4 v4.0.0-20190421002000-1b8f0016e912/go.mod h1:no/Y67Jkk/9WuGR0JG/JseM9irFbnEPbuWV2EELPNuM= 214 | github.com/jackc/pgx/v4 v4.0.0-pre1.0.20190824185557-6972a5742186/go.mod h1:X+GQnOEnf1dqHGpw7JmHqHc1NxDoalibchSk9/RWuDc= 215 | github.com/jackc/puddle v0.0.0-20190413234325-e4ced69a3a2b/go.mod h1:m4B5Dj62Y0fbyuIc15OsIqK0+JU8nkqQjsgx7dvjSWk= 216 | github.com/jackc/puddle v0.0.0-20190608224051-11cab39313c9/go.mod h1:m4B5Dj62Y0fbyuIc15OsIqK0+JU8nkqQjsgx7dvjSWk= 217 | github.com/jmespath/go-jmespath v0.0.0-20180206201540-c2b33e8439af/go.mod h1:Nht3zPeWKUH0NzdCt2Blrr5ys8VGpn0CEB0cQHVjt7k= 218 | github.com/jmoiron/sqlx v1.2.0/go.mod h1:1FEQNm3xlJgrMD+FBdI9+xvCksHtbpVBBw5dYhBSsks= 219 | github.com/jstemmer/go-junit-report v0.0.0-20190106144839-af01ea7f8024/go.mod h1:6v2b51hI/fHJwM22ozAgKL4VKDeJcHhJFhtBdhmNjmU= 220 | github.com/jstemmer/go-junit-report v0.9.1/go.mod h1:Brl9GWCQeLvo8nXZwPNNblvFj/XSXhF0NWZEnDohbsk= 221 | github.com/kardianos/osext v0.0.0-20190222173326-2bc1f35cddc0/go.mod h1:1NbS8ALrpOvjt0rHPNLyCIeMtbizbir8U//inJ+zuB8= 222 | github.com/kisielk/errcheck v1.2.0/go.mod h1:/BMXB+zMLi60iA8Vv6Ksmxu/1UDYcXs4uQLJ+jE2L00= 223 | github.com/kisielk/gotool v1.0.0/go.mod h1:XhKaO+MFFWcvkIS/tQcRk01m1F5IRFswLeQ+oQHNcck= 224 | github.com/konsorten/go-windows-terminal-sequences v1.0.1/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= 225 | github.com/konsorten/go-windows-terminal-sequences v1.0.2/go.mod h1:T0+1ngSBFLxvqU3pZ+m/2kptfBszLMUkC4ZK/EgS/cQ= 226 | github.com/kr/pretty v0.1.0 h1:L/CwN0zerZDmRFUapSPitk6f+Q3+0za1rQkzVuMiMFI= 227 | github.com/kr/pretty v0.1.0/go.mod h1:dAy3ld7l9f0ibDNOQOHHMYYIIbhfbHSm3C4ZsoJORNo= 228 | github.com/kr/pty v1.1.1/go.mod h1:pFQYn66WHrOpPYNljwOMqo10TkYh1fy3cYio2l3bCsQ= 229 | github.com/kr/pty v1.1.8/go.mod h1:O1sed60cT9XZ5uDucP5qwvh+TE3NnUj51EiZO/lmSfw= 230 | github.com/kr/text v0.1.0 h1:45sCR5RtlFHMR4UwH9sdQ5TC8v0qDQCHnXt+kaKSTVE= 231 | github.com/kr/text v0.1.0/go.mod h1:4Jbv+DJW3UT/LiOwJeYQe1efqtUx/iVham/4vfdArNI= 232 | github.com/lib/pq v1.0.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= 233 | github.com/lib/pq v1.1.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= 234 | github.com/lib/pq v1.2.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= 235 | github.com/lib/pq v1.3.0/go.mod h1:5WUZQaWbwv1U+lTReE5YruASi9Al49XbQIvNi/34Woo= 236 | github.com/logrusorgru/aurora v0.0.0-20200102142835-e9ef32dff381/go.mod h1:7rIyQOR62GCctdiQpZ/zOJlFyk6y+94wXzv6RNZgaR4= 237 | github.com/markbates/pkger v0.15.1/go.mod h1:0JoVlrol20BSywW79rN3kdFFsE5xYM+rSCQDXbLhiuI= 238 | github.com/matryer/moq v0.0.0-20200106131100-75d0ddfc0007/go.mod h1:9ELz6aaclSIGnZBoaSLZ3NAl1VTufbOrXBPvtcy6WiQ= 239 | github.com/mattn/go-colorable v0.1.1/go.mod h1:FuOcm+DKB9mbwrcAfNl7/TZVBZ6rcnceauSikq3lYCQ= 240 | github.com/mattn/go-colorable v0.1.4/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= 241 | github.com/mattn/go-isatty v0.0.5/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= 242 | github.com/mattn/go-isatty v0.0.7/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= 243 | github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= 244 | github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU= 245 | github.com/mattn/go-sqlite3 v1.9.0/go.mod h1:FPy6KqzDD04eiIsT53CuJW3U88zkxoIYsOqkbpncsNc= 246 | github.com/mattn/go-sqlite3 v1.10.0/go.mod h1:FPy6KqzDD04eiIsT53CuJW3U88zkxoIYsOqkbpncsNc= 247 | github.com/mitchellh/mapstructure v0.0.0-20180203102830-a4e142e9c047 h1:zCoDWFD5nrJJVjbXiDZcVhOBSzKn3o9LgRLLMRNuru8= 248 | github.com/mitchellh/mapstructure v0.0.0-20180203102830-a4e142e9c047/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= 249 | github.com/morikuni/aec v1.0.0/go.mod h1:BbKIizmSmc5MMPqRYbxO4ZU0S0+P200+tUnFx7PXmsc= 250 | github.com/nakagami/firebirdsql v0.0.0-20190310045651-3c02a58cfed8/go.mod h1:86wM1zFnC6/uDBfZGNwB65O+pR2OFi5q/YQaEUid1qA= 251 | github.com/neo4j/neo4j-go-driver v1.8.1-0.20200803113522-b626aa943eba/go.mod h1:ncO5VaFWh0Nrt+4KT4mOZboaczBZcLuHrG+/sUeP8gI= 252 | github.com/onsi/ginkgo v1.6.0/go.mod h1:lLunBs/Ym6LB5Z9jYTR76FiuTmxDTDusOGeTQH+WWjE= 253 | github.com/onsi/ginkgo v1.12.0/go.mod h1:oUhWkIvk5aDxtKvDDuw8gItl8pKl42LzjC9KZE0HfGg= 254 | github.com/onsi/gomega v1.7.1/go.mod h1:XdKZgCCFLUoM/7CFJVPcG8C1xQ1AJ0vpAezJrB7JYyY= 255 | github.com/onsi/gomega v1.9.0/go.mod h1:Ho0h+IUsWyvy1OpqCwxlQ/21gkhVunqlU8fDGcoTdcA= 256 | github.com/opencontainers/go-digest v1.0.0-rc1 h1:WzifXhOVOEOuFYOJAW6aQqW0TooG2iki3E3Ii+WN7gQ= 257 | github.com/opencontainers/go-digest v1.0.0-rc1/go.mod h1:cMLVZDEM3+U2I4VmLI6N8jQYUd2OVphdqWwCJHrFt2s= 258 | github.com/opencontainers/image-spec v1.0.1/go.mod h1:BtxoFyWECRxE4U/7sNtV5W15zMzWCbyJoFRP3s7yZA0= 259 | github.com/opentracing/basictracer-go v1.0.0/go.mod h1:QfBfYuafItcjQuMwinw9GhYKwFXS9KnPs5lxoYwgW74= 260 | github.com/opentracing/opentracing-go v1.0.2/go.mod h1:UkNAQd3GIcIGf0SeVgPpRdFStlNbqXla1AfSYxPUl2o= 261 | github.com/pierrec/lz4 v2.0.5+incompatible/go.mod h1:pdkljMzZIN41W+lC3N2tnIh5sFi+IEE17M5jbnwPHcY= 262 | github.com/pkg/browser v0.0.0-20180916011732-0a3d74bf9ce4/go.mod h1:4OwLy04Bl9Ef3GJJCoec+30X3LQs/0/m4HFRt/2LUSA= 263 | github.com/pkg/errors v0.8.1 h1:iURUrRGxPUNPdy5/HRSm+Yj6okJ6UtLINN0Q9M4+h3I= 264 | github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= 265 | github.com/pkg/errors v0.9.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0= 266 | github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= 267 | github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= 268 | github.com/prometheus/client_model v0.0.0-20190812154241-14fe0d1b01d4/go.mod h1:xMI15A0UPsDsEKsMN9yxemIoYk6Tm2C1GtYGdfGttqA= 269 | github.com/remyoudompheng/bigfft v0.0.0-20190728182440-6a916e37a237/go.mod h1:qqbHyh8v60DhA7CoWK5oRCqLrMHRGoxYCSS9EjAz6Eo= 270 | github.com/rogpeppe/go-internal v1.3.0/go.mod h1:M8bDsm7K2OlrFYOpmOWEs/qY81heoFRclV5y23lUDJ4= 271 | github.com/rs/cors v1.6.0/go.mod h1:gFx+x8UowdsKA9AchylcLynDq+nNFfI8FkUZdN/jGCU= 272 | github.com/rs/xid v1.2.1/go.mod h1:+uKXf+4Djp6Md1KODXJxgGQPKngRmWyn10oCKFzNHOQ= 273 | github.com/rs/zerolog v1.13.0/go.mod h1:YbFCdg8HfsridGWAh22vktObvhZbQsZXe4/zB0OKkWU= 274 | github.com/rs/zerolog v1.15.0/go.mod h1:xYTKnLHcpfU2225ny5qZjxnj9NvkumZYjJHlAThCjNc= 275 | github.com/russross/blackfriday/v2 v2.0.1 h1:lPqVAte+HuHNfhJ/0LC98ESWRz8afy9tM/0RK8m9o+Q= 276 | github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= 277 | github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0= 278 | github.com/sergi/go-diff v1.0.0 h1:Kpca3qRNrduNnOQeazBd0ysaKrUJiIuISHxogkT9RPQ= 279 | github.com/sergi/go-diff v1.0.0/go.mod h1:0CfEIISq7TuYL3j771MWULgwwjU+GofnZX9QAmXWZgo= 280 | github.com/sergi/go-diff v1.1.0 h1:we8PVUC3FE2uYfodKH/nBHMSetSfHDR6scGdBi+erh0= 281 | github.com/sergi/go-diff v1.1.0/go.mod h1:STckp+ISIX8hZLjrqAeVduY0gWCT9IjLuqbuNXdaHfM= 282 | github.com/shopspring/decimal v0.0.0-20180709203117-cd690d0c9e24/go.mod h1:M+9NzErvs504Cn4c5DxATwIqPbtswREoFCre64PpcG4= 283 | github.com/shurcooL/httpfs v0.0.0-20171119174359-809beceb2371/go.mod h1:ZY1cvUeJuFPAdZ/B6v7RHavJWZn2YPVFQ1OSXhCGOkg= 284 | github.com/shurcooL/sanitized_anchor_name v1.0.0 h1:PdmoCO6wvbs+7yrJyMORt4/BmY5IYyJwS/kOiWx8mHo= 285 | github.com/shurcooL/sanitized_anchor_name v1.0.0/go.mod h1:1NzhyTcUVG4SuEtjjoZeVRXNmyL/1OwPU0+IJeTBvfc= 286 | github.com/shurcooL/vfsgen v0.0.0-20180121065927-ffb13db8def0/go.mod h1:TrYk7fJVaAttu97ZZKrO9UbRa8izdowaMIZcxYMbVaw= 287 | github.com/sirupsen/logrus v1.2.0/go.mod h1:LxeOpSwHxABJmUn/MG1IvRgCAasNZTLOkJPxbbu5VWo= 288 | github.com/sirupsen/logrus v1.4.1/go.mod h1:ni0Sbl8bgC9z8RoU9G6nDWqqs/fq4eDPysMBDgk/93Q= 289 | github.com/sirupsen/logrus v1.4.2/go.mod h1:tLMulIdttU9McNUspp0xgXVQah82FyeX6MwdIuYE2rE= 290 | github.com/snowflakedb/glog v0.0.0-20180824191149-f5055e6f21ce/go.mod h1:EB/w24pR5VKI60ecFnKqXzxX3dOorz1rnVicQTQrGM0= 291 | github.com/snowflakedb/gosnowflake v1.3.5/go.mod h1:13Ky+lxzIm3VqNDZJdyvu9MCGy+WgRdYFdXp96UcLZU= 292 | github.com/spf13/pflag v1.0.3/go.mod h1:DYY7MBk1bdzusC3SYhjObp+wFpr4gzcvqqNjLnInEg4= 293 | github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= 294 | github.com/stretchr/objx v0.1.1/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME= 295 | github.com/stretchr/objx v0.2.0/go.mod h1:qt09Ya8vawLte6SNmTgCsAVtYtaKzEcn8ATUoHMkEqE= 296 | github.com/stretchr/testify v1.2.0/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= 297 | github.com/stretchr/testify v1.2.1/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= 298 | github.com/stretchr/testify v1.2.2/go.mod h1:a8OnRcib4nhh0OaRAV+Yts87kKdq0PP7pXfy6kDkUVs= 299 | github.com/stretchr/testify v1.3.0 h1:TivCn/peBQ7UY8ooIcPgZFpTNSz0Q2U6UrFlUfqbe0Q= 300 | github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI= 301 | github.com/stretchr/testify v1.4.0 h1:2E4SXV/wtOkTonXsotYi4li6zVWxYlZuYNCXe9XRJyk= 302 | github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4= 303 | github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA= 304 | github.com/tidwall/pretty v0.0.0-20180105212114-65a9db5fad51/go.mod h1:XNkn88O1ChpSDQmQeStsy+sBenx6DDtFZJxhVysOjyk= 305 | github.com/urfave/cli v1.20.0 h1:fDqGv3UG/4jbVl/QkFwEdddtEDjh/5Ov6X+0B/3bPaw= 306 | github.com/urfave/cli v1.20.0/go.mod h1:70zkFmudgCuE/ngEzBv17Jvp/497gISqfk5gWijbERA= 307 | github.com/urfave/cli/v2 v2.1.1 h1:Qt8FeAtxE/vfdrLmR3rxR6JRE0RoVmbXu8+6kZtYU4k= 308 | github.com/urfave/cli/v2 v2.1.1/go.mod h1:SE9GqnLQmjVa0iPEY0f1w3ygNIYcIJ0OKPMoW2caLfQ= 309 | github.com/vektah/dataloaden v0.2.1-0.20190515034641-a19b9a6e7c9e/go.mod h1:/HUdMve7rvxZma+2ZELQeNh88+003LL7Pf/CZ089j8U= 310 | github.com/vektah/gqlparser v1.2.0/go.mod h1:bkVf0FX+Stjg/MHnm8mEyubuaArhNEqfQhF+OTiAL74= 311 | github.com/vektah/gqlparser v1.3.1 h1:8b0IcD3qZKWJQHSzynbDlrtP3IxVydZ2DZepCGofqfU= 312 | github.com/vektah/gqlparser v1.3.1/go.mod h1:bkVf0FX+Stjg/MHnm8mEyubuaArhNEqfQhF+OTiAL74= 313 | github.com/vektah/gqlparser/v2 v2.0.1 h1:xgl5abVnsd4hkN9rk65OJID9bfcLSMuTaTcZj777q1o= 314 | github.com/vektah/gqlparser/v2 v2.0.1/go.mod h1:SyUiHgLATUR8BiYURfTirrTcGpcE+4XkV2se04Px1Ms= 315 | github.com/xanzy/go-gitlab v0.15.0/go.mod h1:8zdQa/ri1dfn8eS3Ir1SyfvOKlw7WBJ8DVThkpGiXrs= 316 | github.com/xdg/scram v0.0.0-20180814205039-7eeb5667e42c/go.mod h1:lB8K/P019DLNhemzwFU4jHLhdvlE6uDZjXFejJXr49I= 317 | github.com/xdg/stringprep v1.0.0/go.mod h1:Jhud4/sHMO4oL310DaZAKk9ZaJ08SJfe+sJh0HrGL1Y= 318 | github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= 319 | github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= 320 | github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= 321 | github.com/zenazn/goji v0.9.0/go.mod h1:7S9M489iMyHBNxwZnk9/EHS098H4/F6TATF2mIxtB1Q= 322 | gitlab.com/nyarla/go-crypt v0.0.0-20160106005555-d9a5dc2b789b/go.mod h1:T3BPAOm2cqquPa0MKWeNkmOM5RQsRhkrwMWonFMN7fE= 323 | go.mongodb.org/mongo-driver v1.1.0/go.mod h1:u7ryQJ+DOzQmeO7zB6MHyr8jkEQvC8vH7qLUO4lqsUM= 324 | go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU= 325 | go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8= 326 | go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= 327 | go.opencensus.io v0.22.3/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= 328 | go.opencensus.io v0.22.4/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw= 329 | go.uber.org/atomic v1.3.2/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= 330 | go.uber.org/atomic v1.4.0/go.mod h1:gD2HeocX3+yG+ygLZcrzQJaqmWj9AIm7n08wl/qW/PE= 331 | go.uber.org/multierr v1.1.0/go.mod h1:wR5kodmAFQ0UK8QlbwjlSNy0Z68gJhDJUG5sjR94q/0= 332 | go.uber.org/zap v1.9.1/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= 333 | go.uber.org/zap v1.10.0/go.mod h1:vwi/ZaCAaUcBkycHslxD9B2zi4UTXhF60s6SWpuDF0Q= 334 | golang.org/x/crypto v0.0.0-20180904163835-0709b304e793/go.mod h1:6SG95UA2DQfeDnfUPMdvaQW0Q7yPrPDi9nlGo2tz2b4= 335 | golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2 h1:VklqNMn3ovrHsnt90PveolxSbWFaJdECFbxSq0Mqo2M= 336 | golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= 337 | golang.org/x/crypto v0.0.0-20190325154230-a5d413f7728c/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w= 338 | golang.org/x/crypto v0.0.0-20190411191339-88737f569e3a/go.mod h1:WFFai1msRO1wXaEeE5yQxYXgSfI8pQAWXbQop6sCtWE= 339 | golang.org/x/crypto v0.0.0-20190510104115-cbcb75029529/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 340 | golang.org/x/crypto v0.0.0-20190605123033-f99c8df09eb5/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 341 | golang.org/x/crypto v0.0.0-20190820162420-60c769a6c586/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 342 | golang.org/x/crypto v0.0.0-20191011191535-87dc89f01550/go.mod h1:yigFU9vqHzYiE8UmvKecakEJjdnWj3jj499lnFckfCI= 343 | golang.org/x/crypto v0.0.0-20200510223506-06a226fb4e37/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= 344 | golang.org/x/crypto v0.0.0-20200604202706-70a84ac30bf9 h1:vEg9joUBmeBcK9iSJftGNf3coIG4HqZElCPehJsfAYM= 345 | golang.org/x/crypto v0.0.0-20200604202706-70a84ac30bf9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= 346 | golang.org/x/crypto v0.0.0-20200622213623-75b288015ac9/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= 347 | golang.org/x/crypto v0.0.0-20200709230013-948cd5f35899 h1:DZhuSZLsGlFL4CmhA8BcRA0mnthyA/nZ00AqCUo7vHg= 348 | golang.org/x/crypto v0.0.0-20200709230013-948cd5f35899/go.mod h1:LzIPMQfyMNhhGPhUkYOs5KpL4U8rLKemX1yGLhDgUto= 349 | golang.org/x/exp v0.0.0-20190121172915-509febef88a4/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= 350 | golang.org/x/exp v0.0.0-20190306152737-a1d7652674e8/go.mod h1:CJ0aWSM057203Lf6IL+f9T1iT9GByDxfZKAQTCR3kQA= 351 | golang.org/x/exp v0.0.0-20190510132918-efd6b22b2522/go.mod h1:ZjyILWgesfNpC6sMxTJOJm9Kp84zZh5NQWvqDGG3Qr8= 352 | golang.org/x/exp v0.0.0-20190829153037-c13cbed26979/go.mod h1:86+5VVa7VpoJ4kLfm080zCjGlMRFzhUhsZKEZO7MGek= 353 | golang.org/x/exp v0.0.0-20191030013958-a1ab85dbe136/go.mod h1:JXzH8nQsPlswgeRAPE3MuO9GYsAcnJvJ4vnMwN/5qkY= 354 | golang.org/x/exp v0.0.0-20191129062945-2f5052295587/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4= 355 | golang.org/x/exp v0.0.0-20191227195350-da58074b4299/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4= 356 | golang.org/x/exp v0.0.0-20200119233911-0405dc783f0a/go.mod h1:2RIsYlXP63K8oxa1u096TMicItID8zy7Y6sNkU49FU4= 357 | golang.org/x/exp v0.0.0-20200207192155-f17229e696bd/go.mod h1:J/WKrq2StrnmMY6+EHIKF9dgMWnmCNThgcyBT1FY9mM= 358 | golang.org/x/exp v0.0.0-20200224162631-6cc2880d07d6/go.mod h1:3jZMyOhIsHpP37uCMkUooju7aAi5cS1Q23tOzKc+0MU= 359 | golang.org/x/image v0.0.0-20190227222117-0694c2d4d067/go.mod h1:kZ7UVZpmo3dzQBMxlp+ypCbDeSB+sBbTgSJuh5dn5js= 360 | golang.org/x/image v0.0.0-20190802002840-cff245a6509b/go.mod h1:FeLwcggjj3mMvU+oOTbSwawSJRM1uh48EjtB4UJZlP0= 361 | golang.org/x/lint v0.0.0-20181026193005-c67002cb31c3/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= 362 | golang.org/x/lint v0.0.0-20190227174305-5b3e6a55c961/go.mod h1:wehouNa3lNwaWXcvxsM5YxQ5yQlVC4a0KAMCusXpPoU= 363 | golang.org/x/lint v0.0.0-20190301231843-5614ed5bae6f/go.mod h1:UVdnD1Gm6xHRNCYTkRU2/jEulfH38KcIWyp/GAMgvoE= 364 | golang.org/x/lint v0.0.0-20190313153728-d0100b6bd8b3/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= 365 | golang.org/x/lint v0.0.0-20190409202823-959b441ac422/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= 366 | golang.org/x/lint v0.0.0-20190909230951-414d861bb4ac/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= 367 | golang.org/x/lint v0.0.0-20190930215403-16217165b5de/go.mod h1:6SW0HCj/g11FgYtHlgUYUwCkIfeOF89ocIRzGO/8vkc= 368 | golang.org/x/lint v0.0.0-20191125180803-fdd1cda4f05f/go.mod h1:5qLYkcX4OjUUV8bRuDixDT3tpyyb+LUpUlRWLxfhWrs= 369 | golang.org/x/lint v0.0.0-20200130185559-910be7a94367/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= 370 | golang.org/x/lint v0.0.0-20200302205851-738671d3881b/go.mod h1:3xt1FjdF8hUf6vQPIChWIBhFzV8gjjsPE/fR3IyQdNY= 371 | golang.org/x/mobile v0.0.0-20190312151609-d3739f865fa6/go.mod h1:z+o9i4GpDbdi3rU15maQ/Ox0txvL9dWGYEHz965HBQE= 372 | golang.org/x/mobile v0.0.0-20190719004257-d2bd2a29d028/go.mod h1:E/iHnbuqvinMTCcRqshq8CkpyQDoeVncDDYHnLhea+o= 373 | golang.org/x/mod v0.0.0-20190513183733-4bf6d317e70e/go.mod h1:mXi4GBBbnImb6dmsKGUJ2LatrhH/nqhxcFungHvyanc= 374 | golang.org/x/mod v0.1.0/go.mod h1:0QHyrYULN0/3qlju5TqG8bIK38QM8yzMo5ekMj3DlcY= 375 | golang.org/x/mod v0.1.1-0.20191105210325-c90efee705ee/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg= 376 | golang.org/x/mod v0.1.1-0.20191107180719-034126e5016b/go.mod h1:QqPTAvyqsEbceGzBzNggFXnrqF1CaUcvgkdR5Ot7KZg= 377 | golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= 378 | golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= 379 | golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= 380 | golang.org/x/net v0.0.0-20180826012351-8a410e7b638d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= 381 | golang.org/x/net v0.0.0-20180906233101-161cd47e91fd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= 382 | golang.org/x/net v0.0.0-20181108082009-03003ca0c849/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= 383 | golang.org/x/net v0.0.0-20190108225652-1e06a53dbb7e/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= 384 | golang.org/x/net v0.0.0-20190213061140-3a22650c66bd/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= 385 | golang.org/x/net v0.0.0-20190311183353-d8887717615a h1:oWX7TPOiFAMXLq8o0ikBYfCJVlRHBcsciT5bXOrH628= 386 | golang.org/x/net v0.0.0-20190311183353-d8887717615a/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= 387 | golang.org/x/net v0.0.0-20190404232315-eb5bcb51f2a3/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= 388 | golang.org/x/net v0.0.0-20190501004415-9ce7a6920f09/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= 389 | golang.org/x/net v0.0.0-20190503192946-f4e77d36d62c/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg= 390 | golang.org/x/net v0.0.0-20190603091049-60506f45cf65/go.mod h1:HSz+uSET+XFnRR8LxR5pz3Of3rY3CfYBVs4xY44aLks= 391 | golang.org/x/net v0.0.0-20190620200207-3b0461eec859 h1:R/3boaszxrf1GEUWTVDzSKVwLmSJpwZ1yqXm8j0v2QI= 392 | golang.org/x/net v0.0.0-20190620200207-3b0461eec859/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= 393 | golang.org/x/net v0.0.0-20190628185345-da137c7871d7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= 394 | golang.org/x/net v0.0.0-20190724013045-ca1201d0de80/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= 395 | golang.org/x/net v0.0.0-20190813141303-74dc4d7220e7/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= 396 | golang.org/x/net v0.0.0-20191209160850-c0dbc17a3553/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= 397 | golang.org/x/net v0.0.0-20200114155413-6afb5195e5aa/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= 398 | golang.org/x/net v0.0.0-20200202094626-16171245cfb2/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= 399 | golang.org/x/net v0.0.0-20200222125558-5a598a2470a0/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= 400 | golang.org/x/net v0.0.0-20200226121028-0de0cce0169b/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= 401 | golang.org/x/net v0.0.0-20200301022130-244492dfa37a/go.mod h1:z5CRVTTTmAJ677TzLLGU+0bjPO0LkuOLi4/5GtJWs/s= 402 | golang.org/x/net v0.0.0-20200324143707-d3edc9973b7e/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= 403 | golang.org/x/net v0.0.0-20200501053045-e0ff5e5a1de5/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= 404 | golang.org/x/net v0.0.0-20200506145744-7e3656a0809f/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= 405 | golang.org/x/net v0.0.0-20200513185701-a91f0712d120/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= 406 | golang.org/x/net v0.0.0-20200520182314-0ba52f642ac2/go.mod h1:qpuaurCH72eLCgpAm/N6yyVIVM9cpaDIP3A8BGJEC5A= 407 | golang.org/x/net v0.0.0-20200625001655-4c5254603344/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= 408 | golang.org/x/net v0.0.0-20200707034311-ab3426394381/go.mod h1:/O7V0waA8r7cgGh81Ro3o1hOxt32SMVPicZroKQ2sZA= 409 | golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= 410 | golang.org/x/oauth2 v0.0.0-20181106182150-f42d05182288/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= 411 | golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= 412 | golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= 413 | golang.org/x/oauth2 v0.0.0-20191202225959-858c2ad4c8b6/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= 414 | golang.org/x/oauth2 v0.0.0-20200107190931-bf48bf16ab8d/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= 415 | golang.org/x/sync v0.0.0-20180314180146-1d60e4601c6f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= 416 | golang.org/x/sync v0.0.0-20181108010431-42b317875d0f/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= 417 | golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= 418 | golang.org/x/sync v0.0.0-20190227155943-e225da77a7e6/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= 419 | golang.org/x/sync v0.0.0-20190423024810-112230192c58/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= 420 | golang.org/x/sync v0.0.0-20190911185100-cd5d95a43a6e/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= 421 | golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= 422 | golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= 423 | golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= 424 | golang.org/x/sys v0.0.0-20180905080454-ebe1bf3edb33/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= 425 | golang.org/x/sys v0.0.0-20180909124046-d0be0721c37e/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= 426 | golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= 427 | golang.org/x/sys v0.0.0-20190222072716-a9d3bda3a223/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= 428 | golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 429 | golang.org/x/sys v0.0.0-20190403152447-81d4e9dc473e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 430 | golang.org/x/sys v0.0.0-20190412213103-97732733099d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 431 | golang.org/x/sys v0.0.0-20190422165155-953cdadca894/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 432 | golang.org/x/sys v0.0.0-20190502145724-3ef323f4f1fd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 433 | golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b h1:ag/x1USPSsqHud38I9BAC88qdNLDHHtQ4mlgQIZPPNA= 434 | golang.org/x/sys v0.0.0-20190507160741-ecd444e8653b/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 435 | golang.org/x/sys v0.0.0-20190606165138-5da285871e9c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 436 | golang.org/x/sys v0.0.0-20190624142023-c5567b49c5d0/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 437 | golang.org/x/sys v0.0.0-20190726091711-fc99dfbffb4e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 438 | golang.org/x/sys v0.0.0-20190813064441-fde4db37ae7a/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 439 | golang.org/x/sys v0.0.0-20191001151750-bb3f8db39f24/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 440 | golang.org/x/sys v0.0.0-20191120155948-bd437916bb0e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 441 | golang.org/x/sys v0.0.0-20191204072324-ce4227a45e2e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 442 | golang.org/x/sys v0.0.0-20191228213918-04cbcbbfeed8/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 443 | golang.org/x/sys v0.0.0-20200113162924-86b910548bc1/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 444 | golang.org/x/sys v0.0.0-20200116001909-b77594299b42 h1:vEOn+mP2zCOVzKckCZy6YsCtDblrpj/w7B9nxGNELpg= 445 | golang.org/x/sys v0.0.0-20200116001909-b77594299b42/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 446 | golang.org/x/sys v0.0.0-20200122134326-e047566fdf82/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 447 | golang.org/x/sys v0.0.0-20200202164722-d101bd2416d5/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 448 | golang.org/x/sys v0.0.0-20200212091648-12a6c2dcc1e4/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 449 | golang.org/x/sys v0.0.0-20200223170610-d5e6a3e2c0ae/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 450 | golang.org/x/sys v0.0.0-20200302150141-5c8b2ff67527/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 451 | golang.org/x/sys v0.0.0-20200323222414-85ca7c5b95cd/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 452 | golang.org/x/sys v0.0.0-20200331124033-c3d80250170d/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 453 | golang.org/x/sys v0.0.0-20200501052902-10377860bb8e/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 454 | golang.org/x/sys v0.0.0-20200511232937-7e40ca221e25/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 455 | golang.org/x/sys v0.0.0-20200515095857-1151b9dac4a9/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 456 | golang.org/x/sys v0.0.0-20200523222454-059865788121/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 457 | golang.org/x/sys v0.0.0-20200724161237-0e2f3a69832c/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs= 458 | golang.org/x/text v0.0.0-20170915032832-14c0d48ead0c/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= 459 | golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= 460 | golang.org/x/text v0.3.1-0.20180807135948-17ff2d5776d2/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ= 461 | golang.org/x/text v0.3.2/go.mod h1:bEr9sfX3Q8Zfm5fL9x+3itogRgK3+ptLWKqgva+5dAk= 462 | golang.org/x/text v0.3.3/go.mod h1:5Zoc/QRtKVWzQhOtBMvqHzDpF6irO9z98xDceosuGiQ= 463 | golang.org/x/time v0.0.0-20181108054448-85acf8d2951c/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= 464 | golang.org/x/time v0.0.0-20190308202827-9d24e82272b4/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= 465 | golang.org/x/time v0.0.0-20191024005414-555d28b269f0/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= 466 | golang.org/x/time v0.0.0-20200630173020-3af7569d3a1e/go.mod h1:tRJNPiyCQ0inRvYxbN9jk5I+vvW/OXSQhTDSoE431IQ= 467 | golang.org/x/tools v0.0.0-20180828015842-6cd1fcedba52/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= 468 | golang.org/x/tools v0.0.0-20180917221912-90fa682c2a6e/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= 469 | golang.org/x/tools v0.0.0-20181030221726-6c7e314b6563/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= 470 | golang.org/x/tools v0.0.0-20190114222345-bf090417da8b/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= 471 | golang.org/x/tools v0.0.0-20190125232054-d66bd3c5d5a6/go.mod h1:n7NCudcB/nEzxVGmLbDWY5pfWTLqBcC2KZ6jyYvM4mQ= 472 | golang.org/x/tools v0.0.0-20190226205152-f727befe758c/go.mod h1:9Yl7xja0Znq3iFh3HoIrodX9oNMXvdceNzlUR8zjMvY= 473 | golang.org/x/tools v0.0.0-20190311212946-11955173bddd/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= 474 | golang.org/x/tools v0.0.0-20190312151545-0bb0c0a6e846/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= 475 | golang.org/x/tools v0.0.0-20190312170243-e65039ee4138/go.mod h1:LCzVGOaR6xXOjkQ3onu1FJEFr0SW1gC7cKk1uF8kGRs= 476 | golang.org/x/tools v0.0.0-20190425150028-36563e24a262/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= 477 | golang.org/x/tools v0.0.0-20190425163242-31fd60d6bfdc/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= 478 | golang.org/x/tools v0.0.0-20190506145303-2d16b83fe98c/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= 479 | golang.org/x/tools v0.0.0-20190515012406-7d7faa4812bd/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= 480 | golang.org/x/tools v0.0.0-20190524140312-2c0ae7006135/go.mod h1:RgjU9mgBXZiqYHBnxXauZ1Gv1EHHAz9KjViQ78xBX0Q= 481 | golang.org/x/tools v0.0.0-20190606124116-d0a3d012864b/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= 482 | golang.org/x/tools v0.0.0-20190621195816-6e04913cbbac/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= 483 | golang.org/x/tools v0.0.0-20190624222133-a101b041ded4/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= 484 | golang.org/x/tools v0.0.0-20190628153133-6cdbf07be9d0/go.mod h1:/rFqwRUd4F7ZHNgwSSTFct+R/Kf4OFW1sUzUTQQTgfc= 485 | golang.org/x/tools v0.0.0-20190816200558-6889da9d5479/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= 486 | golang.org/x/tools v0.0.0-20190823170909-c4a336ef6a2f/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= 487 | golang.org/x/tools v0.0.0-20190911174233-4f2ddba30aff/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= 488 | golang.org/x/tools v0.0.0-20191012152004-8de300cfc20a/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= 489 | golang.org/x/tools v0.0.0-20191113191852-77e3bb0ad9e7/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= 490 | golang.org/x/tools v0.0.0-20191115202509-3a792d9c32b2/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= 491 | golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= 492 | golang.org/x/tools v0.0.0-20191125144606-a911d9008d1f/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= 493 | golang.org/x/tools v0.0.0-20191130070609-6e064ea0cf2d/go.mod h1:b+2E5dAYhXwXZwtnZ6UAqBI28+e2cm9otk0dWdXHAEo= 494 | golang.org/x/tools v0.0.0-20191216173652-a0e659d51361/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= 495 | golang.org/x/tools v0.0.0-20191227053925-7b8e75db28f4/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= 496 | golang.org/x/tools v0.0.0-20200114235610-7ae403b6b589 h1:rjUrONFu4kLchcZTfp3/96bR8bW8dIa8uz3cR5n0cgM= 497 | golang.org/x/tools v0.0.0-20200114235610-7ae403b6b589/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= 498 | golang.org/x/tools v0.0.0-20200117161641-43d50277825c/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= 499 | golang.org/x/tools v0.0.0-20200122220014-bf1340f18c4a/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= 500 | golang.org/x/tools v0.0.0-20200130002326-2f3ba24bd6e7/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= 501 | golang.org/x/tools v0.0.0-20200204074204-1cc6d1ef6c74/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= 502 | golang.org/x/tools v0.0.0-20200207183749-b753a1ba74fa/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= 503 | golang.org/x/tools v0.0.0-20200212150539-ea181f53ac56/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= 504 | golang.org/x/tools v0.0.0-20200224181240-023911ca70b2/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= 505 | golang.org/x/tools v0.0.0-20200227222343-706bc42d1f0d/go.mod h1:TB2adYChydJhpapKDTa4BR/hXlZSLoq2Wpct/0txZ28= 506 | golang.org/x/tools v0.0.0-20200304193943-95d2e580d8eb/go.mod h1:o4KQGtdN14AW+yjsvvwRTJJuXz8XRtIHtEnmAXLyFUw= 507 | golang.org/x/tools v0.0.0-20200312045724-11d5b4c81c7d/go.mod h1:o4KQGtdN14AW+yjsvvwRTJJuXz8XRtIHtEnmAXLyFUw= 508 | golang.org/x/tools v0.0.0-20200331025713-a30bf2db82d4/go.mod h1:Sl4aGygMT6LrqrWclx+PTx3U+LnKx/seiNR+3G19Ar8= 509 | golang.org/x/tools v0.0.0-20200501065659-ab2804fb9c9d/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= 510 | golang.org/x/tools v0.0.0-20200512131952-2bc93b1c0c88/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= 511 | golang.org/x/tools v0.0.0-20200515010526-7d3b6ebf133d/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= 512 | golang.org/x/tools v0.0.0-20200618134242-20370b0cb4b2/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= 513 | golang.org/x/tools v0.0.0-20200626171337-aa94e735be7f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= 514 | golang.org/x/tools v0.0.0-20200713011307-fd294ab11aed/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= 515 | golang.org/x/tools v0.0.0-20200717024301-6ddee64345a6/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= 516 | golang.org/x/tools v0.0.0-20200725200936-102e7d357031/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= 517 | golang.org/x/xerrors v0.0.0-20190410155217-1f06c39b4373/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= 518 | golang.org/x/xerrors v0.0.0-20190513163551-3ee3066db522/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= 519 | golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= 520 | golang.org/x/xerrors v0.0.0-20191011141410-1b5146add898/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= 521 | golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= 522 | google.golang.org/api v0.4.0/go.mod h1:8k5glujaEP+g9n7WNsDg8QP6cUVNI86fCNMcbazEtwE= 523 | google.golang.org/api v0.7.0/go.mod h1:WtwebWUNSVBH/HAw79HIFXZNqEvBhG+Ra+ax0hx3E3M= 524 | google.golang.org/api v0.8.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg= 525 | google.golang.org/api v0.9.0/go.mod h1:o4eAsZoiT+ibD93RtjEohWalFOjRDx6CVaqeizhEnKg= 526 | google.golang.org/api v0.13.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI= 527 | google.golang.org/api v0.14.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI= 528 | google.golang.org/api v0.15.0/go.mod h1:iLdEw5Ide6rF15KTC1Kkl0iskquN2gFfn9o9XIsbkAI= 529 | google.golang.org/api v0.17.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE= 530 | google.golang.org/api v0.18.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE= 531 | google.golang.org/api v0.19.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE= 532 | google.golang.org/api v0.20.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE= 533 | google.golang.org/api v0.22.0/go.mod h1:BwFmGc8tA3vsd7r/7kR8DY7iEEGSU04BFxCo5jP/sfE= 534 | google.golang.org/api v0.24.0/go.mod h1:lIXQywCXRcnZPGlsd8NbLnOjtAoL6em04bJ9+z0MncE= 535 | google.golang.org/api v0.28.0/go.mod h1:lIXQywCXRcnZPGlsd8NbLnOjtAoL6em04bJ9+z0MncE= 536 | google.golang.org/api v0.29.0/go.mod h1:Lcubydp8VUV7KeIHD9z2Bys/sm/vGKnG1UHuDBSrHWM= 537 | google.golang.org/appengine v1.1.0/go.mod h1:EbEs0AVv82hx2wNQdGPgUI5lhzA/G0D9YwlJXL52JkM= 538 | google.golang.org/appengine v1.3.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= 539 | google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= 540 | google.golang.org/appengine v1.5.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7/EB5XEv4= 541 | google.golang.org/appengine v1.6.1/go.mod h1:i06prIuMbXzDqacNJfV5OdTW448YApPu5ww/cMBSeb0= 542 | google.golang.org/appengine v1.6.5/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= 543 | google.golang.org/appengine v1.6.6/go.mod h1:8WjMMxjGQR8xUklV/ARdw2HLXBOI7O7uCIDZVag1xfc= 544 | google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc= 545 | google.golang.org/genproto v0.0.0-20190307195333-5fe7a883aa19/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= 546 | google.golang.org/genproto v0.0.0-20190418145605-e7d98fc518a7/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= 547 | google.golang.org/genproto v0.0.0-20190425155659-357c62f0e4bb/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= 548 | google.golang.org/genproto v0.0.0-20190502173448-54afdca5d873/go.mod h1:VzzqZJRnGkLBvHegQrXjBqPurQTc5/KpmUdxsrq26oE= 549 | google.golang.org/genproto v0.0.0-20190801165951-fa694d86fc64/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= 550 | google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc= 551 | google.golang.org/genproto v0.0.0-20190911173649-1774047e7e51/go.mod h1:IbNlFCBrqXvoKpeg0TB2l7cyZUmoaFKYIwrEpbDKLA8= 552 | google.golang.org/genproto v0.0.0-20191108220845-16a3f7862a1a/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= 553 | google.golang.org/genproto v0.0.0-20191115194625-c23dd37a84c9/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= 554 | google.golang.org/genproto v0.0.0-20191216164720-4f79533eabd1/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= 555 | google.golang.org/genproto v0.0.0-20191230161307-f3c370f40bfb/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= 556 | google.golang.org/genproto v0.0.0-20200115191322-ca5a22157cba/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= 557 | google.golang.org/genproto v0.0.0-20200122232147-0452cf42e150/go.mod h1:n3cpQtvxv34hfy77yVDNjmbRyujviMdxYliBSkLhpCc= 558 | google.golang.org/genproto v0.0.0-20200204135345-fa8e72b47b90/go.mod h1:GmwEX6Z4W5gMy59cAlVYjN9JhxgbQH6Gn+gFDQe2lzA= 559 | google.golang.org/genproto v0.0.0-20200212174721-66ed5ce911ce/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= 560 | google.golang.org/genproto v0.0.0-20200224152610-e50cd9704f63/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= 561 | google.golang.org/genproto v0.0.0-20200228133532-8c2c7df3a383/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= 562 | google.golang.org/genproto v0.0.0-20200305110556-506484158171/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= 563 | google.golang.org/genproto v0.0.0-20200312145019-da6875a35672/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= 564 | google.golang.org/genproto v0.0.0-20200331122359-1ee6d9798940/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= 565 | google.golang.org/genproto v0.0.0-20200430143042-b979b6f78d84/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= 566 | google.golang.org/genproto v0.0.0-20200511104702-f5ebc3bea380/go.mod h1:55QSHmfGQM9UVYDPBsyGGes0y52j32PQ3BqQfXhyH3c= 567 | google.golang.org/genproto v0.0.0-20200515170657-fc4c6c6a6587/go.mod h1:YsZOwe1myG/8QRHRsmBRE1LrgQY60beZKjly0O1fX9U= 568 | google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo= 569 | google.golang.org/genproto v0.0.0-20200618031413-b414f8b61790/go.mod h1:jDfRM7FcilCzHH/e9qn6dsT145K34l5v+OpcnNgKAAA= 570 | google.golang.org/genproto v0.0.0-20200626011028-ee7919e894b5/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= 571 | google.golang.org/genproto v0.0.0-20200711021454-869866162049/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= 572 | google.golang.org/genproto v0.0.0-20200720141249-1244ee217b7e/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= 573 | google.golang.org/genproto v0.0.0-20200726014623-da3ae01ef02d/go.mod h1:FWY/as6DDZQgahTzZj3fqbO1CbirC29ZNUFHwi0/+no= 574 | google.golang.org/grpc v1.17.0/go.mod h1:6QZJwpn2B+Zp71q/5VxRsJ6NXXVCE5NRUHRo+f3cWCs= 575 | google.golang.org/grpc v1.19.0/go.mod h1:mqu4LbDTu4XGKhr4mRzUsmM4RtVoemTSY81AxZiDr8c= 576 | google.golang.org/grpc v1.20.1/go.mod h1:10oTOabMzJvdu6/UiuZezV6QK5dSlG84ov/aaiqXj38= 577 | google.golang.org/grpc v1.21.1/go.mod h1:oYelfM1adQP15Ek0mdvEgi9Df8B9CZIaU1084ijfRaM= 578 | google.golang.org/grpc v1.23.0/go.mod h1:Y5yQAOtifL1yxbo5wqy6BxZv8vAUGQwXBOALyacEbxg= 579 | google.golang.org/grpc v1.25.1/go.mod h1:c3i+UQWmh7LiEpx4sFZnkU36qjEYZ0imhYfXVyQciAY= 580 | google.golang.org/grpc v1.26.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= 581 | google.golang.org/grpc v1.27.0/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= 582 | google.golang.org/grpc v1.27.1/go.mod h1:qbnxyOmOxrQa7FizSgH+ReBfzJrCY1pSN7KXBS8abTk= 583 | google.golang.org/grpc v1.28.0/go.mod h1:rpkK4SK4GF4Ach/+MFLZUBavHOvF2JJB5uozKKal+60= 584 | google.golang.org/grpc v1.29.1/go.mod h1:itym6AZVZYACWQqET3MqgPpjcuV5QH3BxFS3IjizoKk= 585 | google.golang.org/grpc v1.30.0/go.mod h1:N36X2cJ7JwdamYAgDz+s+rVMFjt3numwzf/HckM8pak= 586 | google.golang.org/protobuf v0.0.0-20200109180630-ec00e32a8dfd/go.mod h1:DFci5gLYBciE7Vtevhsrf46CRTquxDuWsQurQQe4oz8= 587 | google.golang.org/protobuf v0.0.0-20200221191635-4d8936d0db64/go.mod h1:kwYJMbMJ01Woi6D6+Kah6886xMZcty6N08ah7+eCXa0= 588 | google.golang.org/protobuf v0.0.0-20200228230310-ab0ca4ff8a60/go.mod h1:cfTl7dwQJ+fmap5saPgwCLgHXTUD7jkjRqWcaiX5VyM= 589 | google.golang.org/protobuf v1.20.1-0.20200309200217-e05f789c0967/go.mod h1:A+miEFZTKqfCUM6K7xSMQL9OKL/b6hQv+e19PK+JZNE= 590 | google.golang.org/protobuf v1.21.0/go.mod h1:47Nbq4nVaFHyn7ilMalzfO3qCViNmqZ2kzikPIcrTAo= 591 | google.golang.org/protobuf v1.22.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= 592 | google.golang.org/protobuf v1.23.0/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= 593 | google.golang.org/protobuf v1.23.1-0.20200526195155-81db48ad09cc/go.mod h1:EGpADcykh3NcUnDUJcl1+ZksZNG86OlYog2l/sGQquU= 594 | google.golang.org/protobuf v1.24.0/go.mod h1:r/3tXBNzIEhYS9I1OUVjXDlt8tc493IdKGjtUeSXeh4= 595 | google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlbajtzgsN7c= 596 | gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= 597 | gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127 h1:qIbj1fsPNlZgppZ+VLlY7N33q108Sa+fhmuc+sWQYwY= 598 | gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= 599 | gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15 h1:YR8cESwS4TdDjEe65xsg0ogRM/Nc3DYOhEAlW+xobZo= 600 | gopkg.in/check.v1 v1.0.0-20190902080502-41f04d3bba15/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= 601 | gopkg.in/errgo.v2 v2.1.0/go.mod h1:hNsd1EY+bozCKY1Ytp96fpM3vjJbqLJn88ws8XvfDNI= 602 | gopkg.in/fsnotify.v1 v1.4.7/go.mod h1:Tz8NjZHkW78fSQdbUxIjBTcgA1z1m8ZHf0WmKUhAMys= 603 | gopkg.in/inconshreveable/log15.v2 v2.0.0-20180818164646-67afb5ed74ec/go.mod h1:aPpfJ7XW+gOuirDoZ8gHhLh3kZ1B08FtV2bbmy7Jv3s= 604 | gopkg.in/inf.v0 v0.9.1/go.mod h1:cWUDdTG/fYaXco+Dcufb5Vnc6Gp2YChqWtbxRZE0mXw= 605 | gopkg.in/tomb.v1 v1.0.0-20141024135613-dd632973f1e7/go.mod h1:dt/ZhP58zS4L8KSrWDmTeBkI65Dw0HsyUHuEVlX15mw= 606 | gopkg.in/yaml.v2 v2.2.2 h1:ZCJp+EgiOT7lHqUV2J862kp8Qj64Jo6az82+3Td9dZw= 607 | gopkg.in/yaml.v2 v2.2.2/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= 608 | gopkg.in/yaml.v2 v2.2.4 h1:/eiJrUcujPVeJ3xlSWaiNi3uSVmDGBK1pDHUHAnao1I= 609 | gopkg.in/yaml.v2 v2.2.4/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= 610 | gopkg.in/yaml.v2 v2.2.7/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= 611 | gotest.tools/v3 v3.0.2/go.mod h1:3SzNCllyD9/Y+b5r9JIKQ474KzkZyqLqEfYqMsX94Bk= 612 | honnef.co/go/tools v0.0.0-20180728063816-88497007e858/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= 613 | honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= 614 | honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= 615 | honnef.co/go/tools v0.0.0-20190418001031-e561f6794a2a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= 616 | honnef.co/go/tools v0.0.0-20190523083050-ea95bdfd59fc/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= 617 | honnef.co/go/tools v0.0.1-2019.2.3/go.mod h1:a3bituU0lyd329TUQxRnasdCoJDkEUEAqEt0JzvZhAg= 618 | honnef.co/go/tools v0.0.1-2020.1.3/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= 619 | honnef.co/go/tools v0.0.1-2020.1.4/go.mod h1:X/FiERA/W4tHapMX5mGpAtMSVEeEUOyHaw9vFzvIQ3k= 620 | modernc.org/b v1.0.0/go.mod h1:uZWcZfRj1BpYzfN9JTerzlNUnnPsV9O2ZA8JsRcubNg= 621 | modernc.org/db v1.0.0/go.mod h1:kYD/cO29L/29RM0hXYl4i3+Q5VojL31kTUVpVJDw0s8= 622 | modernc.org/file v1.0.0/go.mod h1:uqEokAEn1u6e+J45e54dsEA/pw4o7zLrA2GwyntZzjw= 623 | modernc.org/fileutil v1.0.0/go.mod h1:JHsWpkrk/CnVV1H/eGlFf85BEpfkrp56ro8nojIq9Q8= 624 | modernc.org/golex v1.0.0/go.mod h1:b/QX9oBD/LhixY6NDh+IdGv17hgB+51fET1i2kPSmvk= 625 | modernc.org/internal v1.0.0/go.mod h1:VUD/+JAkhCpvkUitlEOnhpVxCgsBI90oTzSCRcqQVSM= 626 | modernc.org/lldb v1.0.0/go.mod h1:jcRvJGWfCGodDZz8BPwiKMJxGJngQ/5DrRapkQnLob8= 627 | modernc.org/mathutil v1.0.0/go.mod h1:wU0vUrJsVWBZ4P6e7xtFJEhFSNsfRLJ8H458uRjg03k= 628 | modernc.org/ql v1.0.0/go.mod h1:xGVyrLIatPcO2C1JvI/Co8c0sr6y91HKFNy4pt9JXEY= 629 | modernc.org/sortutil v1.1.0/go.mod h1:ZyL98OQHJgH9IEfN71VsamvJgrtRX9Dj2gX+vH86L1k= 630 | modernc.org/strutil v1.1.0/go.mod h1:lstksw84oURvj9y3tn8lGvRxyRC1S2+g5uuIzNfIOBs= 631 | modernc.org/zappy v1.0.0/go.mod h1:hHe+oGahLVII/aTTyWK/b53VDHMAGCBYYeZ9sn83HC4= 632 | rsc.io/binaryregexp v0.2.0/go.mod h1:qTv7/COck+e2FymRvadv62gMdZztPaShugOCi3I+8D8= 633 | rsc.io/quote/v3 v3.1.0/go.mod h1:yEA65RcK8LyAZtP9Kv3t0HmxON59tX3rD+tICJqUlj0= 634 | rsc.io/sampler v1.3.0/go.mod h1:T1hPZKmBbMNahiBKFy5HrXp6adAjACjK9JXDnKaTXpA= 635 | sourcegraph.com/sourcegraph/appdash v0.0.0-20180110180208-2cc67fd64755/go.mod h1:hI742Nqp5OhwiqlzhgfbWU4mW4yO10fP+LoT9WOswdU= 636 | sourcegraph.com/sourcegraph/appdash-data v0.0.0-20151005221446-73f23eafcf67/go.mod h1:L5q+DGLGOQFpo1snNEkLOJT2d1YTW66rWNzatr3He1k= 637 | -------------------------------------------------------------------------------- /graph/generated/generated.go: -------------------------------------------------------------------------------- 1 | // Code generated by github.com/99designs/gqlgen, DO NOT EDIT. 2 | 3 | package generated 4 | 5 | import ( 6 | "bytes" 7 | "context" 8 | "errors" 9 | "strconv" 10 | "sync" 11 | "sync/atomic" 12 | 13 | "github.com/99designs/gqlgen/graphql" 14 | "github.com/99designs/gqlgen/graphql/introspection" 15 | "github.com/glyphack/graphlq-golang/graph/model" 16 | gqlparser "github.com/vektah/gqlparser/v2" 17 | "github.com/vektah/gqlparser/v2/ast" 18 | ) 19 | 20 | // region ************************** generated!.gotpl ************************** 21 | 22 | // NewExecutableSchema creates an ExecutableSchema from the ResolverRoot interface. 23 | func NewExecutableSchema(cfg Config) graphql.ExecutableSchema { 24 | return &executableSchema{ 25 | resolvers: cfg.Resolvers, 26 | directives: cfg.Directives, 27 | complexity: cfg.Complexity, 28 | } 29 | } 30 | 31 | type Config struct { 32 | Resolvers ResolverRoot 33 | Directives DirectiveRoot 34 | Complexity ComplexityRoot 35 | } 36 | 37 | type ResolverRoot interface { 38 | Mutation() MutationResolver 39 | Query() QueryResolver 40 | } 41 | 42 | type DirectiveRoot struct { 43 | } 44 | 45 | type ComplexityRoot struct { 46 | Link struct { 47 | Address func(childComplexity int) int 48 | ID func(childComplexity int) int 49 | Title func(childComplexity int) int 50 | User func(childComplexity int) int 51 | } 52 | 53 | Mutation struct { 54 | CreateLink func(childComplexity int, input model.NewLink) int 55 | CreateUser func(childComplexity int, input model.NewUser) int 56 | Login func(childComplexity int, input model.Login) int 57 | RefreshToken func(childComplexity int, input model.RefreshTokenInput) int 58 | } 59 | 60 | Query struct { 61 | Links func(childComplexity int) int 62 | } 63 | 64 | User struct { 65 | ID func(childComplexity int) int 66 | Name func(childComplexity int) int 67 | } 68 | } 69 | 70 | type MutationResolver interface { 71 | CreateLink(ctx context.Context, input model.NewLink) (*model.Link, error) 72 | CreateUser(ctx context.Context, input model.NewUser) (string, error) 73 | Login(ctx context.Context, input model.Login) (string, error) 74 | RefreshToken(ctx context.Context, input model.RefreshTokenInput) (string, error) 75 | } 76 | type QueryResolver interface { 77 | Links(ctx context.Context) ([]*model.Link, error) 78 | } 79 | 80 | type executableSchema struct { 81 | resolvers ResolverRoot 82 | directives DirectiveRoot 83 | complexity ComplexityRoot 84 | } 85 | 86 | func (e *executableSchema) Schema() *ast.Schema { 87 | return parsedSchema 88 | } 89 | 90 | func (e *executableSchema) Complexity(typeName, field string, childComplexity int, rawArgs map[string]interface{}) (int, bool) { 91 | ec := executionContext{nil, e} 92 | _ = ec 93 | switch typeName + "." + field { 94 | 95 | case "Link.address": 96 | if e.complexity.Link.Address == nil { 97 | break 98 | } 99 | 100 | return e.complexity.Link.Address(childComplexity), true 101 | 102 | case "Link.id": 103 | if e.complexity.Link.ID == nil { 104 | break 105 | } 106 | 107 | return e.complexity.Link.ID(childComplexity), true 108 | 109 | case "Link.title": 110 | if e.complexity.Link.Title == nil { 111 | break 112 | } 113 | 114 | return e.complexity.Link.Title(childComplexity), true 115 | 116 | case "Link.user": 117 | if e.complexity.Link.User == nil { 118 | break 119 | } 120 | 121 | return e.complexity.Link.User(childComplexity), true 122 | 123 | case "Mutation.createLink": 124 | if e.complexity.Mutation.CreateLink == nil { 125 | break 126 | } 127 | 128 | args, err := ec.field_Mutation_createLink_args(context.TODO(), rawArgs) 129 | if err != nil { 130 | return 0, false 131 | } 132 | 133 | return e.complexity.Mutation.CreateLink(childComplexity, args["input"].(model.NewLink)), true 134 | 135 | case "Mutation.createUser": 136 | if e.complexity.Mutation.CreateUser == nil { 137 | break 138 | } 139 | 140 | args, err := ec.field_Mutation_createUser_args(context.TODO(), rawArgs) 141 | if err != nil { 142 | return 0, false 143 | } 144 | 145 | return e.complexity.Mutation.CreateUser(childComplexity, args["input"].(model.NewUser)), true 146 | 147 | case "Mutation.login": 148 | if e.complexity.Mutation.Login == nil { 149 | break 150 | } 151 | 152 | args, err := ec.field_Mutation_login_args(context.TODO(), rawArgs) 153 | if err != nil { 154 | return 0, false 155 | } 156 | 157 | return e.complexity.Mutation.Login(childComplexity, args["input"].(model.Login)), true 158 | 159 | case "Mutation.refreshToken": 160 | if e.complexity.Mutation.RefreshToken == nil { 161 | break 162 | } 163 | 164 | args, err := ec.field_Mutation_refreshToken_args(context.TODO(), rawArgs) 165 | if err != nil { 166 | return 0, false 167 | } 168 | 169 | return e.complexity.Mutation.RefreshToken(childComplexity, args["input"].(model.RefreshTokenInput)), true 170 | 171 | case "Query.links": 172 | if e.complexity.Query.Links == nil { 173 | break 174 | } 175 | 176 | return e.complexity.Query.Links(childComplexity), true 177 | 178 | case "User.id": 179 | if e.complexity.User.ID == nil { 180 | break 181 | } 182 | 183 | return e.complexity.User.ID(childComplexity), true 184 | 185 | case "User.name": 186 | if e.complexity.User.Name == nil { 187 | break 188 | } 189 | 190 | return e.complexity.User.Name(childComplexity), true 191 | 192 | } 193 | return 0, false 194 | } 195 | 196 | func (e *executableSchema) Exec(ctx context.Context) graphql.ResponseHandler { 197 | rc := graphql.GetOperationContext(ctx) 198 | ec := executionContext{rc, e} 199 | first := true 200 | 201 | switch rc.Operation.Operation { 202 | case ast.Query: 203 | return func(ctx context.Context) *graphql.Response { 204 | if !first { 205 | return nil 206 | } 207 | first = false 208 | data := ec._Query(ctx, rc.Operation.SelectionSet) 209 | var buf bytes.Buffer 210 | data.MarshalGQL(&buf) 211 | 212 | return &graphql.Response{ 213 | Data: buf.Bytes(), 214 | } 215 | } 216 | case ast.Mutation: 217 | return func(ctx context.Context) *graphql.Response { 218 | if !first { 219 | return nil 220 | } 221 | first = false 222 | data := ec._Mutation(ctx, rc.Operation.SelectionSet) 223 | var buf bytes.Buffer 224 | data.MarshalGQL(&buf) 225 | 226 | return &graphql.Response{ 227 | Data: buf.Bytes(), 228 | } 229 | } 230 | 231 | default: 232 | return graphql.OneShot(graphql.ErrorResponse(ctx, "unsupported GraphQL operation")) 233 | } 234 | } 235 | 236 | type executionContext struct { 237 | *graphql.OperationContext 238 | *executableSchema 239 | } 240 | 241 | func (ec *executionContext) introspectSchema() (*introspection.Schema, error) { 242 | if ec.DisableIntrospection { 243 | return nil, errors.New("introspection disabled") 244 | } 245 | return introspection.WrapSchema(parsedSchema), nil 246 | } 247 | 248 | func (ec *executionContext) introspectType(name string) (*introspection.Type, error) { 249 | if ec.DisableIntrospection { 250 | return nil, errors.New("introspection disabled") 251 | } 252 | return introspection.WrapTypeFromDef(parsedSchema, parsedSchema.Types[name]), nil 253 | } 254 | 255 | var sources = []*ast.Source{ 256 | &ast.Source{Name: "graph/schema.graphqls", Input: `type Link { 257 | id: ID! 258 | title: String! 259 | address: String! 260 | user: User! 261 | } 262 | 263 | type User { 264 | id: ID! 265 | name: String! 266 | } 267 | 268 | type Query { 269 | links: [Link!]! 270 | } 271 | 272 | input NewLink { 273 | title: String! 274 | address: String! 275 | } 276 | 277 | input RefreshTokenInput{ 278 | token: String! 279 | } 280 | 281 | input NewUser { 282 | username: String! 283 | password: String! 284 | } 285 | 286 | input Login { 287 | username: String! 288 | password: String! 289 | } 290 | 291 | type Mutation { 292 | createLink(input: NewLink!): Link! 293 | createUser(input: NewUser!): String! 294 | login(input: Login!): String! 295 | # we'll talk about this in authentication section 296 | refreshToken(input: RefreshTokenInput!): String! 297 | } 298 | `, BuiltIn: false}, 299 | } 300 | var parsedSchema = gqlparser.MustLoadSchema(sources...) 301 | 302 | // endregion ************************** generated!.gotpl ************************** 303 | 304 | // region ***************************** args.gotpl ***************************** 305 | 306 | func (ec *executionContext) field_Mutation_createLink_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 307 | var err error 308 | args := map[string]interface{}{} 309 | var arg0 model.NewLink 310 | if tmp, ok := rawArgs["input"]; ok { 311 | arg0, err = ec.unmarshalNNewLink2githubᚗcomᚋglyphackᚋgraphlqᚑgolangᚋgraphᚋmodelᚐNewLink(ctx, tmp) 312 | if err != nil { 313 | return nil, err 314 | } 315 | } 316 | args["input"] = arg0 317 | return args, nil 318 | } 319 | 320 | func (ec *executionContext) field_Mutation_createUser_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 321 | var err error 322 | args := map[string]interface{}{} 323 | var arg0 model.NewUser 324 | if tmp, ok := rawArgs["input"]; ok { 325 | arg0, err = ec.unmarshalNNewUser2githubᚗcomᚋglyphackᚋgraphlqᚑgolangᚋgraphᚋmodelᚐNewUser(ctx, tmp) 326 | if err != nil { 327 | return nil, err 328 | } 329 | } 330 | args["input"] = arg0 331 | return args, nil 332 | } 333 | 334 | func (ec *executionContext) field_Mutation_login_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 335 | var err error 336 | args := map[string]interface{}{} 337 | var arg0 model.Login 338 | if tmp, ok := rawArgs["input"]; ok { 339 | arg0, err = ec.unmarshalNLogin2githubᚗcomᚋglyphackᚋgraphlqᚑgolangᚋgraphᚋmodelᚐLogin(ctx, tmp) 340 | if err != nil { 341 | return nil, err 342 | } 343 | } 344 | args["input"] = arg0 345 | return args, nil 346 | } 347 | 348 | func (ec *executionContext) field_Mutation_refreshToken_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 349 | var err error 350 | args := map[string]interface{}{} 351 | var arg0 model.RefreshTokenInput 352 | if tmp, ok := rawArgs["input"]; ok { 353 | arg0, err = ec.unmarshalNRefreshTokenInput2githubᚗcomᚋglyphackᚋgraphlqᚑgolangᚋgraphᚋmodelᚐRefreshTokenInput(ctx, tmp) 354 | if err != nil { 355 | return nil, err 356 | } 357 | } 358 | args["input"] = arg0 359 | return args, nil 360 | } 361 | 362 | func (ec *executionContext) field_Query___type_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 363 | var err error 364 | args := map[string]interface{}{} 365 | var arg0 string 366 | if tmp, ok := rawArgs["name"]; ok { 367 | arg0, err = ec.unmarshalNString2string(ctx, tmp) 368 | if err != nil { 369 | return nil, err 370 | } 371 | } 372 | args["name"] = arg0 373 | return args, nil 374 | } 375 | 376 | func (ec *executionContext) field___Type_enumValues_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 377 | var err error 378 | args := map[string]interface{}{} 379 | var arg0 bool 380 | if tmp, ok := rawArgs["includeDeprecated"]; ok { 381 | arg0, err = ec.unmarshalOBoolean2bool(ctx, tmp) 382 | if err != nil { 383 | return nil, err 384 | } 385 | } 386 | args["includeDeprecated"] = arg0 387 | return args, nil 388 | } 389 | 390 | func (ec *executionContext) field___Type_fields_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { 391 | var err error 392 | args := map[string]interface{}{} 393 | var arg0 bool 394 | if tmp, ok := rawArgs["includeDeprecated"]; ok { 395 | arg0, err = ec.unmarshalOBoolean2bool(ctx, tmp) 396 | if err != nil { 397 | return nil, err 398 | } 399 | } 400 | args["includeDeprecated"] = arg0 401 | return args, nil 402 | } 403 | 404 | // endregion ***************************** args.gotpl ***************************** 405 | 406 | // region ************************** directives.gotpl ************************** 407 | 408 | // endregion ************************** directives.gotpl ************************** 409 | 410 | // region **************************** field.gotpl ***************************** 411 | 412 | func (ec *executionContext) _Link_id(ctx context.Context, field graphql.CollectedField, obj *model.Link) (ret graphql.Marshaler) { 413 | defer func() { 414 | if r := recover(); r != nil { 415 | ec.Error(ctx, ec.Recover(ctx, r)) 416 | ret = graphql.Null 417 | } 418 | }() 419 | fc := &graphql.FieldContext{ 420 | Object: "Link", 421 | Field: field, 422 | Args: nil, 423 | IsMethod: false, 424 | } 425 | 426 | ctx = graphql.WithFieldContext(ctx, fc) 427 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 428 | ctx = rctx // use context from middleware stack in children 429 | return obj.ID, nil 430 | }) 431 | if err != nil { 432 | ec.Error(ctx, err) 433 | return graphql.Null 434 | } 435 | if resTmp == nil { 436 | if !graphql.HasFieldError(ctx, fc) { 437 | ec.Errorf(ctx, "must not be null") 438 | } 439 | return graphql.Null 440 | } 441 | res := resTmp.(string) 442 | fc.Result = res 443 | return ec.marshalNID2string(ctx, field.Selections, res) 444 | } 445 | 446 | func (ec *executionContext) _Link_title(ctx context.Context, field graphql.CollectedField, obj *model.Link) (ret graphql.Marshaler) { 447 | defer func() { 448 | if r := recover(); r != nil { 449 | ec.Error(ctx, ec.Recover(ctx, r)) 450 | ret = graphql.Null 451 | } 452 | }() 453 | fc := &graphql.FieldContext{ 454 | Object: "Link", 455 | Field: field, 456 | Args: nil, 457 | IsMethod: false, 458 | } 459 | 460 | ctx = graphql.WithFieldContext(ctx, fc) 461 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 462 | ctx = rctx // use context from middleware stack in children 463 | return obj.Title, nil 464 | }) 465 | if err != nil { 466 | ec.Error(ctx, err) 467 | return graphql.Null 468 | } 469 | if resTmp == nil { 470 | if !graphql.HasFieldError(ctx, fc) { 471 | ec.Errorf(ctx, "must not be null") 472 | } 473 | return graphql.Null 474 | } 475 | res := resTmp.(string) 476 | fc.Result = res 477 | return ec.marshalNString2string(ctx, field.Selections, res) 478 | } 479 | 480 | func (ec *executionContext) _Link_address(ctx context.Context, field graphql.CollectedField, obj *model.Link) (ret graphql.Marshaler) { 481 | defer func() { 482 | if r := recover(); r != nil { 483 | ec.Error(ctx, ec.Recover(ctx, r)) 484 | ret = graphql.Null 485 | } 486 | }() 487 | fc := &graphql.FieldContext{ 488 | Object: "Link", 489 | Field: field, 490 | Args: nil, 491 | IsMethod: false, 492 | } 493 | 494 | ctx = graphql.WithFieldContext(ctx, fc) 495 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 496 | ctx = rctx // use context from middleware stack in children 497 | return obj.Address, nil 498 | }) 499 | if err != nil { 500 | ec.Error(ctx, err) 501 | return graphql.Null 502 | } 503 | if resTmp == nil { 504 | if !graphql.HasFieldError(ctx, fc) { 505 | ec.Errorf(ctx, "must not be null") 506 | } 507 | return graphql.Null 508 | } 509 | res := resTmp.(string) 510 | fc.Result = res 511 | return ec.marshalNString2string(ctx, field.Selections, res) 512 | } 513 | 514 | func (ec *executionContext) _Link_user(ctx context.Context, field graphql.CollectedField, obj *model.Link) (ret graphql.Marshaler) { 515 | defer func() { 516 | if r := recover(); r != nil { 517 | ec.Error(ctx, ec.Recover(ctx, r)) 518 | ret = graphql.Null 519 | } 520 | }() 521 | fc := &graphql.FieldContext{ 522 | Object: "Link", 523 | Field: field, 524 | Args: nil, 525 | IsMethod: false, 526 | } 527 | 528 | ctx = graphql.WithFieldContext(ctx, fc) 529 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 530 | ctx = rctx // use context from middleware stack in children 531 | return obj.User, nil 532 | }) 533 | if err != nil { 534 | ec.Error(ctx, err) 535 | return graphql.Null 536 | } 537 | if resTmp == nil { 538 | if !graphql.HasFieldError(ctx, fc) { 539 | ec.Errorf(ctx, "must not be null") 540 | } 541 | return graphql.Null 542 | } 543 | res := resTmp.(*model.User) 544 | fc.Result = res 545 | return ec.marshalNUser2ᚖgithubᚗcomᚋglyphackᚋgraphlqᚑgolangᚋgraphᚋmodelᚐUser(ctx, field.Selections, res) 546 | } 547 | 548 | func (ec *executionContext) _Mutation_createLink(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 549 | defer func() { 550 | if r := recover(); r != nil { 551 | ec.Error(ctx, ec.Recover(ctx, r)) 552 | ret = graphql.Null 553 | } 554 | }() 555 | fc := &graphql.FieldContext{ 556 | Object: "Mutation", 557 | Field: field, 558 | Args: nil, 559 | IsMethod: true, 560 | } 561 | 562 | ctx = graphql.WithFieldContext(ctx, fc) 563 | rawArgs := field.ArgumentMap(ec.Variables) 564 | args, err := ec.field_Mutation_createLink_args(ctx, rawArgs) 565 | if err != nil { 566 | ec.Error(ctx, err) 567 | return graphql.Null 568 | } 569 | fc.Args = args 570 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 571 | ctx = rctx // use context from middleware stack in children 572 | return ec.resolvers.Mutation().CreateLink(rctx, args["input"].(model.NewLink)) 573 | }) 574 | if err != nil { 575 | ec.Error(ctx, err) 576 | return graphql.Null 577 | } 578 | if resTmp == nil { 579 | if !graphql.HasFieldError(ctx, fc) { 580 | ec.Errorf(ctx, "must not be null") 581 | } 582 | return graphql.Null 583 | } 584 | res := resTmp.(*model.Link) 585 | fc.Result = res 586 | return ec.marshalNLink2ᚖgithubᚗcomᚋglyphackᚋgraphlqᚑgolangᚋgraphᚋmodelᚐLink(ctx, field.Selections, res) 587 | } 588 | 589 | func (ec *executionContext) _Mutation_createUser(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 590 | defer func() { 591 | if r := recover(); r != nil { 592 | ec.Error(ctx, ec.Recover(ctx, r)) 593 | ret = graphql.Null 594 | } 595 | }() 596 | fc := &graphql.FieldContext{ 597 | Object: "Mutation", 598 | Field: field, 599 | Args: nil, 600 | IsMethod: true, 601 | } 602 | 603 | ctx = graphql.WithFieldContext(ctx, fc) 604 | rawArgs := field.ArgumentMap(ec.Variables) 605 | args, err := ec.field_Mutation_createUser_args(ctx, rawArgs) 606 | if err != nil { 607 | ec.Error(ctx, err) 608 | return graphql.Null 609 | } 610 | fc.Args = args 611 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 612 | ctx = rctx // use context from middleware stack in children 613 | return ec.resolvers.Mutation().CreateUser(rctx, args["input"].(model.NewUser)) 614 | }) 615 | if err != nil { 616 | ec.Error(ctx, err) 617 | return graphql.Null 618 | } 619 | if resTmp == nil { 620 | if !graphql.HasFieldError(ctx, fc) { 621 | ec.Errorf(ctx, "must not be null") 622 | } 623 | return graphql.Null 624 | } 625 | res := resTmp.(string) 626 | fc.Result = res 627 | return ec.marshalNString2string(ctx, field.Selections, res) 628 | } 629 | 630 | func (ec *executionContext) _Mutation_login(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 631 | defer func() { 632 | if r := recover(); r != nil { 633 | ec.Error(ctx, ec.Recover(ctx, r)) 634 | ret = graphql.Null 635 | } 636 | }() 637 | fc := &graphql.FieldContext{ 638 | Object: "Mutation", 639 | Field: field, 640 | Args: nil, 641 | IsMethod: true, 642 | } 643 | 644 | ctx = graphql.WithFieldContext(ctx, fc) 645 | rawArgs := field.ArgumentMap(ec.Variables) 646 | args, err := ec.field_Mutation_login_args(ctx, rawArgs) 647 | if err != nil { 648 | ec.Error(ctx, err) 649 | return graphql.Null 650 | } 651 | fc.Args = args 652 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 653 | ctx = rctx // use context from middleware stack in children 654 | return ec.resolvers.Mutation().Login(rctx, args["input"].(model.Login)) 655 | }) 656 | if err != nil { 657 | ec.Error(ctx, err) 658 | return graphql.Null 659 | } 660 | if resTmp == nil { 661 | if !graphql.HasFieldError(ctx, fc) { 662 | ec.Errorf(ctx, "must not be null") 663 | } 664 | return graphql.Null 665 | } 666 | res := resTmp.(string) 667 | fc.Result = res 668 | return ec.marshalNString2string(ctx, field.Selections, res) 669 | } 670 | 671 | func (ec *executionContext) _Mutation_refreshToken(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 672 | defer func() { 673 | if r := recover(); r != nil { 674 | ec.Error(ctx, ec.Recover(ctx, r)) 675 | ret = graphql.Null 676 | } 677 | }() 678 | fc := &graphql.FieldContext{ 679 | Object: "Mutation", 680 | Field: field, 681 | Args: nil, 682 | IsMethod: true, 683 | } 684 | 685 | ctx = graphql.WithFieldContext(ctx, fc) 686 | rawArgs := field.ArgumentMap(ec.Variables) 687 | args, err := ec.field_Mutation_refreshToken_args(ctx, rawArgs) 688 | if err != nil { 689 | ec.Error(ctx, err) 690 | return graphql.Null 691 | } 692 | fc.Args = args 693 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 694 | ctx = rctx // use context from middleware stack in children 695 | return ec.resolvers.Mutation().RefreshToken(rctx, args["input"].(model.RefreshTokenInput)) 696 | }) 697 | if err != nil { 698 | ec.Error(ctx, err) 699 | return graphql.Null 700 | } 701 | if resTmp == nil { 702 | if !graphql.HasFieldError(ctx, fc) { 703 | ec.Errorf(ctx, "must not be null") 704 | } 705 | return graphql.Null 706 | } 707 | res := resTmp.(string) 708 | fc.Result = res 709 | return ec.marshalNString2string(ctx, field.Selections, res) 710 | } 711 | 712 | func (ec *executionContext) _Query_links(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 713 | defer func() { 714 | if r := recover(); r != nil { 715 | ec.Error(ctx, ec.Recover(ctx, r)) 716 | ret = graphql.Null 717 | } 718 | }() 719 | fc := &graphql.FieldContext{ 720 | Object: "Query", 721 | Field: field, 722 | Args: nil, 723 | IsMethod: true, 724 | } 725 | 726 | ctx = graphql.WithFieldContext(ctx, fc) 727 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 728 | ctx = rctx // use context from middleware stack in children 729 | return ec.resolvers.Query().Links(rctx) 730 | }) 731 | if err != nil { 732 | ec.Error(ctx, err) 733 | return graphql.Null 734 | } 735 | if resTmp == nil { 736 | if !graphql.HasFieldError(ctx, fc) { 737 | ec.Errorf(ctx, "must not be null") 738 | } 739 | return graphql.Null 740 | } 741 | res := resTmp.([]*model.Link) 742 | fc.Result = res 743 | return ec.marshalNLink2ᚕᚖgithubᚗcomᚋglyphackᚋgraphlqᚑgolangᚋgraphᚋmodelᚐLinkᚄ(ctx, field.Selections, res) 744 | } 745 | 746 | func (ec *executionContext) _Query___type(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 747 | defer func() { 748 | if r := recover(); r != nil { 749 | ec.Error(ctx, ec.Recover(ctx, r)) 750 | ret = graphql.Null 751 | } 752 | }() 753 | fc := &graphql.FieldContext{ 754 | Object: "Query", 755 | Field: field, 756 | Args: nil, 757 | IsMethod: true, 758 | } 759 | 760 | ctx = graphql.WithFieldContext(ctx, fc) 761 | rawArgs := field.ArgumentMap(ec.Variables) 762 | args, err := ec.field_Query___type_args(ctx, rawArgs) 763 | if err != nil { 764 | ec.Error(ctx, err) 765 | return graphql.Null 766 | } 767 | fc.Args = args 768 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 769 | ctx = rctx // use context from middleware stack in children 770 | return ec.introspectType(args["name"].(string)) 771 | }) 772 | if err != nil { 773 | ec.Error(ctx, err) 774 | return graphql.Null 775 | } 776 | if resTmp == nil { 777 | return graphql.Null 778 | } 779 | res := resTmp.(*introspection.Type) 780 | fc.Result = res 781 | return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) 782 | } 783 | 784 | func (ec *executionContext) _Query___schema(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { 785 | defer func() { 786 | if r := recover(); r != nil { 787 | ec.Error(ctx, ec.Recover(ctx, r)) 788 | ret = graphql.Null 789 | } 790 | }() 791 | fc := &graphql.FieldContext{ 792 | Object: "Query", 793 | Field: field, 794 | Args: nil, 795 | IsMethod: true, 796 | } 797 | 798 | ctx = graphql.WithFieldContext(ctx, fc) 799 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 800 | ctx = rctx // use context from middleware stack in children 801 | return ec.introspectSchema() 802 | }) 803 | if err != nil { 804 | ec.Error(ctx, err) 805 | return graphql.Null 806 | } 807 | if resTmp == nil { 808 | return graphql.Null 809 | } 810 | res := resTmp.(*introspection.Schema) 811 | fc.Result = res 812 | return ec.marshalO__Schema2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐSchema(ctx, field.Selections, res) 813 | } 814 | 815 | func (ec *executionContext) _User_id(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) { 816 | defer func() { 817 | if r := recover(); r != nil { 818 | ec.Error(ctx, ec.Recover(ctx, r)) 819 | ret = graphql.Null 820 | } 821 | }() 822 | fc := &graphql.FieldContext{ 823 | Object: "User", 824 | Field: field, 825 | Args: nil, 826 | IsMethod: false, 827 | } 828 | 829 | ctx = graphql.WithFieldContext(ctx, fc) 830 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 831 | ctx = rctx // use context from middleware stack in children 832 | return obj.ID, nil 833 | }) 834 | if err != nil { 835 | ec.Error(ctx, err) 836 | return graphql.Null 837 | } 838 | if resTmp == nil { 839 | if !graphql.HasFieldError(ctx, fc) { 840 | ec.Errorf(ctx, "must not be null") 841 | } 842 | return graphql.Null 843 | } 844 | res := resTmp.(string) 845 | fc.Result = res 846 | return ec.marshalNID2string(ctx, field.Selections, res) 847 | } 848 | 849 | func (ec *executionContext) _User_name(ctx context.Context, field graphql.CollectedField, obj *model.User) (ret graphql.Marshaler) { 850 | defer func() { 851 | if r := recover(); r != nil { 852 | ec.Error(ctx, ec.Recover(ctx, r)) 853 | ret = graphql.Null 854 | } 855 | }() 856 | fc := &graphql.FieldContext{ 857 | Object: "User", 858 | Field: field, 859 | Args: nil, 860 | IsMethod: false, 861 | } 862 | 863 | ctx = graphql.WithFieldContext(ctx, fc) 864 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 865 | ctx = rctx // use context from middleware stack in children 866 | return obj.Name, nil 867 | }) 868 | if err != nil { 869 | ec.Error(ctx, err) 870 | return graphql.Null 871 | } 872 | if resTmp == nil { 873 | if !graphql.HasFieldError(ctx, fc) { 874 | ec.Errorf(ctx, "must not be null") 875 | } 876 | return graphql.Null 877 | } 878 | res := resTmp.(string) 879 | fc.Result = res 880 | return ec.marshalNString2string(ctx, field.Selections, res) 881 | } 882 | 883 | func (ec *executionContext) ___Directive_name(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) { 884 | defer func() { 885 | if r := recover(); r != nil { 886 | ec.Error(ctx, ec.Recover(ctx, r)) 887 | ret = graphql.Null 888 | } 889 | }() 890 | fc := &graphql.FieldContext{ 891 | Object: "__Directive", 892 | Field: field, 893 | Args: nil, 894 | IsMethod: false, 895 | } 896 | 897 | ctx = graphql.WithFieldContext(ctx, fc) 898 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 899 | ctx = rctx // use context from middleware stack in children 900 | return obj.Name, nil 901 | }) 902 | if err != nil { 903 | ec.Error(ctx, err) 904 | return graphql.Null 905 | } 906 | if resTmp == nil { 907 | if !graphql.HasFieldError(ctx, fc) { 908 | ec.Errorf(ctx, "must not be null") 909 | } 910 | return graphql.Null 911 | } 912 | res := resTmp.(string) 913 | fc.Result = res 914 | return ec.marshalNString2string(ctx, field.Selections, res) 915 | } 916 | 917 | func (ec *executionContext) ___Directive_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) { 918 | defer func() { 919 | if r := recover(); r != nil { 920 | ec.Error(ctx, ec.Recover(ctx, r)) 921 | ret = graphql.Null 922 | } 923 | }() 924 | fc := &graphql.FieldContext{ 925 | Object: "__Directive", 926 | Field: field, 927 | Args: nil, 928 | IsMethod: false, 929 | } 930 | 931 | ctx = graphql.WithFieldContext(ctx, fc) 932 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 933 | ctx = rctx // use context from middleware stack in children 934 | return obj.Description, nil 935 | }) 936 | if err != nil { 937 | ec.Error(ctx, err) 938 | return graphql.Null 939 | } 940 | if resTmp == nil { 941 | return graphql.Null 942 | } 943 | res := resTmp.(string) 944 | fc.Result = res 945 | return ec.marshalOString2string(ctx, field.Selections, res) 946 | } 947 | 948 | func (ec *executionContext) ___Directive_locations(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) { 949 | defer func() { 950 | if r := recover(); r != nil { 951 | ec.Error(ctx, ec.Recover(ctx, r)) 952 | ret = graphql.Null 953 | } 954 | }() 955 | fc := &graphql.FieldContext{ 956 | Object: "__Directive", 957 | Field: field, 958 | Args: nil, 959 | IsMethod: false, 960 | } 961 | 962 | ctx = graphql.WithFieldContext(ctx, fc) 963 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 964 | ctx = rctx // use context from middleware stack in children 965 | return obj.Locations, nil 966 | }) 967 | if err != nil { 968 | ec.Error(ctx, err) 969 | return graphql.Null 970 | } 971 | if resTmp == nil { 972 | if !graphql.HasFieldError(ctx, fc) { 973 | ec.Errorf(ctx, "must not be null") 974 | } 975 | return graphql.Null 976 | } 977 | res := resTmp.([]string) 978 | fc.Result = res 979 | return ec.marshalN__DirectiveLocation2ᚕstringᚄ(ctx, field.Selections, res) 980 | } 981 | 982 | func (ec *executionContext) ___Directive_args(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) { 983 | defer func() { 984 | if r := recover(); r != nil { 985 | ec.Error(ctx, ec.Recover(ctx, r)) 986 | ret = graphql.Null 987 | } 988 | }() 989 | fc := &graphql.FieldContext{ 990 | Object: "__Directive", 991 | Field: field, 992 | Args: nil, 993 | IsMethod: false, 994 | } 995 | 996 | ctx = graphql.WithFieldContext(ctx, fc) 997 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 998 | ctx = rctx // use context from middleware stack in children 999 | return obj.Args, nil 1000 | }) 1001 | if err != nil { 1002 | ec.Error(ctx, err) 1003 | return graphql.Null 1004 | } 1005 | if resTmp == nil { 1006 | if !graphql.HasFieldError(ctx, fc) { 1007 | ec.Errorf(ctx, "must not be null") 1008 | } 1009 | return graphql.Null 1010 | } 1011 | res := resTmp.([]introspection.InputValue) 1012 | fc.Result = res 1013 | return ec.marshalN__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx, field.Selections, res) 1014 | } 1015 | 1016 | func (ec *executionContext) ___EnumValue_name(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) { 1017 | defer func() { 1018 | if r := recover(); r != nil { 1019 | ec.Error(ctx, ec.Recover(ctx, r)) 1020 | ret = graphql.Null 1021 | } 1022 | }() 1023 | fc := &graphql.FieldContext{ 1024 | Object: "__EnumValue", 1025 | Field: field, 1026 | Args: nil, 1027 | IsMethod: false, 1028 | } 1029 | 1030 | ctx = graphql.WithFieldContext(ctx, fc) 1031 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1032 | ctx = rctx // use context from middleware stack in children 1033 | return obj.Name, nil 1034 | }) 1035 | if err != nil { 1036 | ec.Error(ctx, err) 1037 | return graphql.Null 1038 | } 1039 | if resTmp == nil { 1040 | if !graphql.HasFieldError(ctx, fc) { 1041 | ec.Errorf(ctx, "must not be null") 1042 | } 1043 | return graphql.Null 1044 | } 1045 | res := resTmp.(string) 1046 | fc.Result = res 1047 | return ec.marshalNString2string(ctx, field.Selections, res) 1048 | } 1049 | 1050 | func (ec *executionContext) ___EnumValue_description(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) { 1051 | defer func() { 1052 | if r := recover(); r != nil { 1053 | ec.Error(ctx, ec.Recover(ctx, r)) 1054 | ret = graphql.Null 1055 | } 1056 | }() 1057 | fc := &graphql.FieldContext{ 1058 | Object: "__EnumValue", 1059 | Field: field, 1060 | Args: nil, 1061 | IsMethod: false, 1062 | } 1063 | 1064 | ctx = graphql.WithFieldContext(ctx, fc) 1065 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1066 | ctx = rctx // use context from middleware stack in children 1067 | return obj.Description, nil 1068 | }) 1069 | if err != nil { 1070 | ec.Error(ctx, err) 1071 | return graphql.Null 1072 | } 1073 | if resTmp == nil { 1074 | return graphql.Null 1075 | } 1076 | res := resTmp.(string) 1077 | fc.Result = res 1078 | return ec.marshalOString2string(ctx, field.Selections, res) 1079 | } 1080 | 1081 | func (ec *executionContext) ___EnumValue_isDeprecated(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) { 1082 | defer func() { 1083 | if r := recover(); r != nil { 1084 | ec.Error(ctx, ec.Recover(ctx, r)) 1085 | ret = graphql.Null 1086 | } 1087 | }() 1088 | fc := &graphql.FieldContext{ 1089 | Object: "__EnumValue", 1090 | Field: field, 1091 | Args: nil, 1092 | IsMethod: true, 1093 | } 1094 | 1095 | ctx = graphql.WithFieldContext(ctx, fc) 1096 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1097 | ctx = rctx // use context from middleware stack in children 1098 | return obj.IsDeprecated(), nil 1099 | }) 1100 | if err != nil { 1101 | ec.Error(ctx, err) 1102 | return graphql.Null 1103 | } 1104 | if resTmp == nil { 1105 | if !graphql.HasFieldError(ctx, fc) { 1106 | ec.Errorf(ctx, "must not be null") 1107 | } 1108 | return graphql.Null 1109 | } 1110 | res := resTmp.(bool) 1111 | fc.Result = res 1112 | return ec.marshalNBoolean2bool(ctx, field.Selections, res) 1113 | } 1114 | 1115 | func (ec *executionContext) ___EnumValue_deprecationReason(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) { 1116 | defer func() { 1117 | if r := recover(); r != nil { 1118 | ec.Error(ctx, ec.Recover(ctx, r)) 1119 | ret = graphql.Null 1120 | } 1121 | }() 1122 | fc := &graphql.FieldContext{ 1123 | Object: "__EnumValue", 1124 | Field: field, 1125 | Args: nil, 1126 | IsMethod: true, 1127 | } 1128 | 1129 | ctx = graphql.WithFieldContext(ctx, fc) 1130 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1131 | ctx = rctx // use context from middleware stack in children 1132 | return obj.DeprecationReason(), nil 1133 | }) 1134 | if err != nil { 1135 | ec.Error(ctx, err) 1136 | return graphql.Null 1137 | } 1138 | if resTmp == nil { 1139 | return graphql.Null 1140 | } 1141 | res := resTmp.(*string) 1142 | fc.Result = res 1143 | return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 1144 | } 1145 | 1146 | func (ec *executionContext) ___Field_name(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { 1147 | defer func() { 1148 | if r := recover(); r != nil { 1149 | ec.Error(ctx, ec.Recover(ctx, r)) 1150 | ret = graphql.Null 1151 | } 1152 | }() 1153 | fc := &graphql.FieldContext{ 1154 | Object: "__Field", 1155 | Field: field, 1156 | Args: nil, 1157 | IsMethod: false, 1158 | } 1159 | 1160 | ctx = graphql.WithFieldContext(ctx, fc) 1161 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1162 | ctx = rctx // use context from middleware stack in children 1163 | return obj.Name, nil 1164 | }) 1165 | if err != nil { 1166 | ec.Error(ctx, err) 1167 | return graphql.Null 1168 | } 1169 | if resTmp == nil { 1170 | if !graphql.HasFieldError(ctx, fc) { 1171 | ec.Errorf(ctx, "must not be null") 1172 | } 1173 | return graphql.Null 1174 | } 1175 | res := resTmp.(string) 1176 | fc.Result = res 1177 | return ec.marshalNString2string(ctx, field.Selections, res) 1178 | } 1179 | 1180 | func (ec *executionContext) ___Field_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { 1181 | defer func() { 1182 | if r := recover(); r != nil { 1183 | ec.Error(ctx, ec.Recover(ctx, r)) 1184 | ret = graphql.Null 1185 | } 1186 | }() 1187 | fc := &graphql.FieldContext{ 1188 | Object: "__Field", 1189 | Field: field, 1190 | Args: nil, 1191 | IsMethod: false, 1192 | } 1193 | 1194 | ctx = graphql.WithFieldContext(ctx, fc) 1195 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1196 | ctx = rctx // use context from middleware stack in children 1197 | return obj.Description, nil 1198 | }) 1199 | if err != nil { 1200 | ec.Error(ctx, err) 1201 | return graphql.Null 1202 | } 1203 | if resTmp == nil { 1204 | return graphql.Null 1205 | } 1206 | res := resTmp.(string) 1207 | fc.Result = res 1208 | return ec.marshalOString2string(ctx, field.Selections, res) 1209 | } 1210 | 1211 | func (ec *executionContext) ___Field_args(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { 1212 | defer func() { 1213 | if r := recover(); r != nil { 1214 | ec.Error(ctx, ec.Recover(ctx, r)) 1215 | ret = graphql.Null 1216 | } 1217 | }() 1218 | fc := &graphql.FieldContext{ 1219 | Object: "__Field", 1220 | Field: field, 1221 | Args: nil, 1222 | IsMethod: false, 1223 | } 1224 | 1225 | ctx = graphql.WithFieldContext(ctx, fc) 1226 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1227 | ctx = rctx // use context from middleware stack in children 1228 | return obj.Args, nil 1229 | }) 1230 | if err != nil { 1231 | ec.Error(ctx, err) 1232 | return graphql.Null 1233 | } 1234 | if resTmp == nil { 1235 | if !graphql.HasFieldError(ctx, fc) { 1236 | ec.Errorf(ctx, "must not be null") 1237 | } 1238 | return graphql.Null 1239 | } 1240 | res := resTmp.([]introspection.InputValue) 1241 | fc.Result = res 1242 | return ec.marshalN__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx, field.Selections, res) 1243 | } 1244 | 1245 | func (ec *executionContext) ___Field_type(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { 1246 | defer func() { 1247 | if r := recover(); r != nil { 1248 | ec.Error(ctx, ec.Recover(ctx, r)) 1249 | ret = graphql.Null 1250 | } 1251 | }() 1252 | fc := &graphql.FieldContext{ 1253 | Object: "__Field", 1254 | Field: field, 1255 | Args: nil, 1256 | IsMethod: false, 1257 | } 1258 | 1259 | ctx = graphql.WithFieldContext(ctx, fc) 1260 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1261 | ctx = rctx // use context from middleware stack in children 1262 | return obj.Type, nil 1263 | }) 1264 | if err != nil { 1265 | ec.Error(ctx, err) 1266 | return graphql.Null 1267 | } 1268 | if resTmp == nil { 1269 | if !graphql.HasFieldError(ctx, fc) { 1270 | ec.Errorf(ctx, "must not be null") 1271 | } 1272 | return graphql.Null 1273 | } 1274 | res := resTmp.(*introspection.Type) 1275 | fc.Result = res 1276 | return ec.marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) 1277 | } 1278 | 1279 | func (ec *executionContext) ___Field_isDeprecated(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { 1280 | defer func() { 1281 | if r := recover(); r != nil { 1282 | ec.Error(ctx, ec.Recover(ctx, r)) 1283 | ret = graphql.Null 1284 | } 1285 | }() 1286 | fc := &graphql.FieldContext{ 1287 | Object: "__Field", 1288 | Field: field, 1289 | Args: nil, 1290 | IsMethod: true, 1291 | } 1292 | 1293 | ctx = graphql.WithFieldContext(ctx, fc) 1294 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1295 | ctx = rctx // use context from middleware stack in children 1296 | return obj.IsDeprecated(), nil 1297 | }) 1298 | if err != nil { 1299 | ec.Error(ctx, err) 1300 | return graphql.Null 1301 | } 1302 | if resTmp == nil { 1303 | if !graphql.HasFieldError(ctx, fc) { 1304 | ec.Errorf(ctx, "must not be null") 1305 | } 1306 | return graphql.Null 1307 | } 1308 | res := resTmp.(bool) 1309 | fc.Result = res 1310 | return ec.marshalNBoolean2bool(ctx, field.Selections, res) 1311 | } 1312 | 1313 | func (ec *executionContext) ___Field_deprecationReason(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { 1314 | defer func() { 1315 | if r := recover(); r != nil { 1316 | ec.Error(ctx, ec.Recover(ctx, r)) 1317 | ret = graphql.Null 1318 | } 1319 | }() 1320 | fc := &graphql.FieldContext{ 1321 | Object: "__Field", 1322 | Field: field, 1323 | Args: nil, 1324 | IsMethod: true, 1325 | } 1326 | 1327 | ctx = graphql.WithFieldContext(ctx, fc) 1328 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1329 | ctx = rctx // use context from middleware stack in children 1330 | return obj.DeprecationReason(), nil 1331 | }) 1332 | if err != nil { 1333 | ec.Error(ctx, err) 1334 | return graphql.Null 1335 | } 1336 | if resTmp == nil { 1337 | return graphql.Null 1338 | } 1339 | res := resTmp.(*string) 1340 | fc.Result = res 1341 | return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 1342 | } 1343 | 1344 | func (ec *executionContext) ___InputValue_name(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) { 1345 | defer func() { 1346 | if r := recover(); r != nil { 1347 | ec.Error(ctx, ec.Recover(ctx, r)) 1348 | ret = graphql.Null 1349 | } 1350 | }() 1351 | fc := &graphql.FieldContext{ 1352 | Object: "__InputValue", 1353 | Field: field, 1354 | Args: nil, 1355 | IsMethod: false, 1356 | } 1357 | 1358 | ctx = graphql.WithFieldContext(ctx, fc) 1359 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1360 | ctx = rctx // use context from middleware stack in children 1361 | return obj.Name, nil 1362 | }) 1363 | if err != nil { 1364 | ec.Error(ctx, err) 1365 | return graphql.Null 1366 | } 1367 | if resTmp == nil { 1368 | if !graphql.HasFieldError(ctx, fc) { 1369 | ec.Errorf(ctx, "must not be null") 1370 | } 1371 | return graphql.Null 1372 | } 1373 | res := resTmp.(string) 1374 | fc.Result = res 1375 | return ec.marshalNString2string(ctx, field.Selections, res) 1376 | } 1377 | 1378 | func (ec *executionContext) ___InputValue_description(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) { 1379 | defer func() { 1380 | if r := recover(); r != nil { 1381 | ec.Error(ctx, ec.Recover(ctx, r)) 1382 | ret = graphql.Null 1383 | } 1384 | }() 1385 | fc := &graphql.FieldContext{ 1386 | Object: "__InputValue", 1387 | Field: field, 1388 | Args: nil, 1389 | IsMethod: false, 1390 | } 1391 | 1392 | ctx = graphql.WithFieldContext(ctx, fc) 1393 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1394 | ctx = rctx // use context from middleware stack in children 1395 | return obj.Description, nil 1396 | }) 1397 | if err != nil { 1398 | ec.Error(ctx, err) 1399 | return graphql.Null 1400 | } 1401 | if resTmp == nil { 1402 | return graphql.Null 1403 | } 1404 | res := resTmp.(string) 1405 | fc.Result = res 1406 | return ec.marshalOString2string(ctx, field.Selections, res) 1407 | } 1408 | 1409 | func (ec *executionContext) ___InputValue_type(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) { 1410 | defer func() { 1411 | if r := recover(); r != nil { 1412 | ec.Error(ctx, ec.Recover(ctx, r)) 1413 | ret = graphql.Null 1414 | } 1415 | }() 1416 | fc := &graphql.FieldContext{ 1417 | Object: "__InputValue", 1418 | Field: field, 1419 | Args: nil, 1420 | IsMethod: false, 1421 | } 1422 | 1423 | ctx = graphql.WithFieldContext(ctx, fc) 1424 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1425 | ctx = rctx // use context from middleware stack in children 1426 | return obj.Type, nil 1427 | }) 1428 | if err != nil { 1429 | ec.Error(ctx, err) 1430 | return graphql.Null 1431 | } 1432 | if resTmp == nil { 1433 | if !graphql.HasFieldError(ctx, fc) { 1434 | ec.Errorf(ctx, "must not be null") 1435 | } 1436 | return graphql.Null 1437 | } 1438 | res := resTmp.(*introspection.Type) 1439 | fc.Result = res 1440 | return ec.marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) 1441 | } 1442 | 1443 | func (ec *executionContext) ___InputValue_defaultValue(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) { 1444 | defer func() { 1445 | if r := recover(); r != nil { 1446 | ec.Error(ctx, ec.Recover(ctx, r)) 1447 | ret = graphql.Null 1448 | } 1449 | }() 1450 | fc := &graphql.FieldContext{ 1451 | Object: "__InputValue", 1452 | Field: field, 1453 | Args: nil, 1454 | IsMethod: false, 1455 | } 1456 | 1457 | ctx = graphql.WithFieldContext(ctx, fc) 1458 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1459 | ctx = rctx // use context from middleware stack in children 1460 | return obj.DefaultValue, nil 1461 | }) 1462 | if err != nil { 1463 | ec.Error(ctx, err) 1464 | return graphql.Null 1465 | } 1466 | if resTmp == nil { 1467 | return graphql.Null 1468 | } 1469 | res := resTmp.(*string) 1470 | fc.Result = res 1471 | return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 1472 | } 1473 | 1474 | func (ec *executionContext) ___Schema_types(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { 1475 | defer func() { 1476 | if r := recover(); r != nil { 1477 | ec.Error(ctx, ec.Recover(ctx, r)) 1478 | ret = graphql.Null 1479 | } 1480 | }() 1481 | fc := &graphql.FieldContext{ 1482 | Object: "__Schema", 1483 | Field: field, 1484 | Args: nil, 1485 | IsMethod: true, 1486 | } 1487 | 1488 | ctx = graphql.WithFieldContext(ctx, fc) 1489 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1490 | ctx = rctx // use context from middleware stack in children 1491 | return obj.Types(), nil 1492 | }) 1493 | if err != nil { 1494 | ec.Error(ctx, err) 1495 | return graphql.Null 1496 | } 1497 | if resTmp == nil { 1498 | if !graphql.HasFieldError(ctx, fc) { 1499 | ec.Errorf(ctx, "must not be null") 1500 | } 1501 | return graphql.Null 1502 | } 1503 | res := resTmp.([]introspection.Type) 1504 | fc.Result = res 1505 | return ec.marshalN__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx, field.Selections, res) 1506 | } 1507 | 1508 | func (ec *executionContext) ___Schema_queryType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { 1509 | defer func() { 1510 | if r := recover(); r != nil { 1511 | ec.Error(ctx, ec.Recover(ctx, r)) 1512 | ret = graphql.Null 1513 | } 1514 | }() 1515 | fc := &graphql.FieldContext{ 1516 | Object: "__Schema", 1517 | Field: field, 1518 | Args: nil, 1519 | IsMethod: true, 1520 | } 1521 | 1522 | ctx = graphql.WithFieldContext(ctx, fc) 1523 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1524 | ctx = rctx // use context from middleware stack in children 1525 | return obj.QueryType(), nil 1526 | }) 1527 | if err != nil { 1528 | ec.Error(ctx, err) 1529 | return graphql.Null 1530 | } 1531 | if resTmp == nil { 1532 | if !graphql.HasFieldError(ctx, fc) { 1533 | ec.Errorf(ctx, "must not be null") 1534 | } 1535 | return graphql.Null 1536 | } 1537 | res := resTmp.(*introspection.Type) 1538 | fc.Result = res 1539 | return ec.marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) 1540 | } 1541 | 1542 | func (ec *executionContext) ___Schema_mutationType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { 1543 | defer func() { 1544 | if r := recover(); r != nil { 1545 | ec.Error(ctx, ec.Recover(ctx, r)) 1546 | ret = graphql.Null 1547 | } 1548 | }() 1549 | fc := &graphql.FieldContext{ 1550 | Object: "__Schema", 1551 | Field: field, 1552 | Args: nil, 1553 | IsMethod: true, 1554 | } 1555 | 1556 | ctx = graphql.WithFieldContext(ctx, fc) 1557 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1558 | ctx = rctx // use context from middleware stack in children 1559 | return obj.MutationType(), nil 1560 | }) 1561 | if err != nil { 1562 | ec.Error(ctx, err) 1563 | return graphql.Null 1564 | } 1565 | if resTmp == nil { 1566 | return graphql.Null 1567 | } 1568 | res := resTmp.(*introspection.Type) 1569 | fc.Result = res 1570 | return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) 1571 | } 1572 | 1573 | func (ec *executionContext) ___Schema_subscriptionType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { 1574 | defer func() { 1575 | if r := recover(); r != nil { 1576 | ec.Error(ctx, ec.Recover(ctx, r)) 1577 | ret = graphql.Null 1578 | } 1579 | }() 1580 | fc := &graphql.FieldContext{ 1581 | Object: "__Schema", 1582 | Field: field, 1583 | Args: nil, 1584 | IsMethod: true, 1585 | } 1586 | 1587 | ctx = graphql.WithFieldContext(ctx, fc) 1588 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1589 | ctx = rctx // use context from middleware stack in children 1590 | return obj.SubscriptionType(), nil 1591 | }) 1592 | if err != nil { 1593 | ec.Error(ctx, err) 1594 | return graphql.Null 1595 | } 1596 | if resTmp == nil { 1597 | return graphql.Null 1598 | } 1599 | res := resTmp.(*introspection.Type) 1600 | fc.Result = res 1601 | return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) 1602 | } 1603 | 1604 | func (ec *executionContext) ___Schema_directives(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { 1605 | defer func() { 1606 | if r := recover(); r != nil { 1607 | ec.Error(ctx, ec.Recover(ctx, r)) 1608 | ret = graphql.Null 1609 | } 1610 | }() 1611 | fc := &graphql.FieldContext{ 1612 | Object: "__Schema", 1613 | Field: field, 1614 | Args: nil, 1615 | IsMethod: true, 1616 | } 1617 | 1618 | ctx = graphql.WithFieldContext(ctx, fc) 1619 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1620 | ctx = rctx // use context from middleware stack in children 1621 | return obj.Directives(), nil 1622 | }) 1623 | if err != nil { 1624 | ec.Error(ctx, err) 1625 | return graphql.Null 1626 | } 1627 | if resTmp == nil { 1628 | if !graphql.HasFieldError(ctx, fc) { 1629 | ec.Errorf(ctx, "must not be null") 1630 | } 1631 | return graphql.Null 1632 | } 1633 | res := resTmp.([]introspection.Directive) 1634 | fc.Result = res 1635 | return ec.marshalN__Directive2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirectiveᚄ(ctx, field.Selections, res) 1636 | } 1637 | 1638 | func (ec *executionContext) ___Type_kind(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { 1639 | defer func() { 1640 | if r := recover(); r != nil { 1641 | ec.Error(ctx, ec.Recover(ctx, r)) 1642 | ret = graphql.Null 1643 | } 1644 | }() 1645 | fc := &graphql.FieldContext{ 1646 | Object: "__Type", 1647 | Field: field, 1648 | Args: nil, 1649 | IsMethod: true, 1650 | } 1651 | 1652 | ctx = graphql.WithFieldContext(ctx, fc) 1653 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1654 | ctx = rctx // use context from middleware stack in children 1655 | return obj.Kind(), nil 1656 | }) 1657 | if err != nil { 1658 | ec.Error(ctx, err) 1659 | return graphql.Null 1660 | } 1661 | if resTmp == nil { 1662 | if !graphql.HasFieldError(ctx, fc) { 1663 | ec.Errorf(ctx, "must not be null") 1664 | } 1665 | return graphql.Null 1666 | } 1667 | res := resTmp.(string) 1668 | fc.Result = res 1669 | return ec.marshalN__TypeKind2string(ctx, field.Selections, res) 1670 | } 1671 | 1672 | func (ec *executionContext) ___Type_name(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { 1673 | defer func() { 1674 | if r := recover(); r != nil { 1675 | ec.Error(ctx, ec.Recover(ctx, r)) 1676 | ret = graphql.Null 1677 | } 1678 | }() 1679 | fc := &graphql.FieldContext{ 1680 | Object: "__Type", 1681 | Field: field, 1682 | Args: nil, 1683 | IsMethod: true, 1684 | } 1685 | 1686 | ctx = graphql.WithFieldContext(ctx, fc) 1687 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1688 | ctx = rctx // use context from middleware stack in children 1689 | return obj.Name(), nil 1690 | }) 1691 | if err != nil { 1692 | ec.Error(ctx, err) 1693 | return graphql.Null 1694 | } 1695 | if resTmp == nil { 1696 | return graphql.Null 1697 | } 1698 | res := resTmp.(*string) 1699 | fc.Result = res 1700 | return ec.marshalOString2ᚖstring(ctx, field.Selections, res) 1701 | } 1702 | 1703 | func (ec *executionContext) ___Type_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { 1704 | defer func() { 1705 | if r := recover(); r != nil { 1706 | ec.Error(ctx, ec.Recover(ctx, r)) 1707 | ret = graphql.Null 1708 | } 1709 | }() 1710 | fc := &graphql.FieldContext{ 1711 | Object: "__Type", 1712 | Field: field, 1713 | Args: nil, 1714 | IsMethod: true, 1715 | } 1716 | 1717 | ctx = graphql.WithFieldContext(ctx, fc) 1718 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1719 | ctx = rctx // use context from middleware stack in children 1720 | return obj.Description(), nil 1721 | }) 1722 | if err != nil { 1723 | ec.Error(ctx, err) 1724 | return graphql.Null 1725 | } 1726 | if resTmp == nil { 1727 | return graphql.Null 1728 | } 1729 | res := resTmp.(string) 1730 | fc.Result = res 1731 | return ec.marshalOString2string(ctx, field.Selections, res) 1732 | } 1733 | 1734 | func (ec *executionContext) ___Type_fields(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { 1735 | defer func() { 1736 | if r := recover(); r != nil { 1737 | ec.Error(ctx, ec.Recover(ctx, r)) 1738 | ret = graphql.Null 1739 | } 1740 | }() 1741 | fc := &graphql.FieldContext{ 1742 | Object: "__Type", 1743 | Field: field, 1744 | Args: nil, 1745 | IsMethod: true, 1746 | } 1747 | 1748 | ctx = graphql.WithFieldContext(ctx, fc) 1749 | rawArgs := field.ArgumentMap(ec.Variables) 1750 | args, err := ec.field___Type_fields_args(ctx, rawArgs) 1751 | if err != nil { 1752 | ec.Error(ctx, err) 1753 | return graphql.Null 1754 | } 1755 | fc.Args = args 1756 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1757 | ctx = rctx // use context from middleware stack in children 1758 | return obj.Fields(args["includeDeprecated"].(bool)), nil 1759 | }) 1760 | if err != nil { 1761 | ec.Error(ctx, err) 1762 | return graphql.Null 1763 | } 1764 | if resTmp == nil { 1765 | return graphql.Null 1766 | } 1767 | res := resTmp.([]introspection.Field) 1768 | fc.Result = res 1769 | return ec.marshalO__Field2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐFieldᚄ(ctx, field.Selections, res) 1770 | } 1771 | 1772 | func (ec *executionContext) ___Type_interfaces(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { 1773 | defer func() { 1774 | if r := recover(); r != nil { 1775 | ec.Error(ctx, ec.Recover(ctx, r)) 1776 | ret = graphql.Null 1777 | } 1778 | }() 1779 | fc := &graphql.FieldContext{ 1780 | Object: "__Type", 1781 | Field: field, 1782 | Args: nil, 1783 | IsMethod: true, 1784 | } 1785 | 1786 | ctx = graphql.WithFieldContext(ctx, fc) 1787 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1788 | ctx = rctx // use context from middleware stack in children 1789 | return obj.Interfaces(), nil 1790 | }) 1791 | if err != nil { 1792 | ec.Error(ctx, err) 1793 | return graphql.Null 1794 | } 1795 | if resTmp == nil { 1796 | return graphql.Null 1797 | } 1798 | res := resTmp.([]introspection.Type) 1799 | fc.Result = res 1800 | return ec.marshalO__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx, field.Selections, res) 1801 | } 1802 | 1803 | func (ec *executionContext) ___Type_possibleTypes(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { 1804 | defer func() { 1805 | if r := recover(); r != nil { 1806 | ec.Error(ctx, ec.Recover(ctx, r)) 1807 | ret = graphql.Null 1808 | } 1809 | }() 1810 | fc := &graphql.FieldContext{ 1811 | Object: "__Type", 1812 | Field: field, 1813 | Args: nil, 1814 | IsMethod: true, 1815 | } 1816 | 1817 | ctx = graphql.WithFieldContext(ctx, fc) 1818 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1819 | ctx = rctx // use context from middleware stack in children 1820 | return obj.PossibleTypes(), nil 1821 | }) 1822 | if err != nil { 1823 | ec.Error(ctx, err) 1824 | return graphql.Null 1825 | } 1826 | if resTmp == nil { 1827 | return graphql.Null 1828 | } 1829 | res := resTmp.([]introspection.Type) 1830 | fc.Result = res 1831 | return ec.marshalO__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx, field.Selections, res) 1832 | } 1833 | 1834 | func (ec *executionContext) ___Type_enumValues(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { 1835 | defer func() { 1836 | if r := recover(); r != nil { 1837 | ec.Error(ctx, ec.Recover(ctx, r)) 1838 | ret = graphql.Null 1839 | } 1840 | }() 1841 | fc := &graphql.FieldContext{ 1842 | Object: "__Type", 1843 | Field: field, 1844 | Args: nil, 1845 | IsMethod: true, 1846 | } 1847 | 1848 | ctx = graphql.WithFieldContext(ctx, fc) 1849 | rawArgs := field.ArgumentMap(ec.Variables) 1850 | args, err := ec.field___Type_enumValues_args(ctx, rawArgs) 1851 | if err != nil { 1852 | ec.Error(ctx, err) 1853 | return graphql.Null 1854 | } 1855 | fc.Args = args 1856 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1857 | ctx = rctx // use context from middleware stack in children 1858 | return obj.EnumValues(args["includeDeprecated"].(bool)), nil 1859 | }) 1860 | if err != nil { 1861 | ec.Error(ctx, err) 1862 | return graphql.Null 1863 | } 1864 | if resTmp == nil { 1865 | return graphql.Null 1866 | } 1867 | res := resTmp.([]introspection.EnumValue) 1868 | fc.Result = res 1869 | return ec.marshalO__EnumValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValueᚄ(ctx, field.Selections, res) 1870 | } 1871 | 1872 | func (ec *executionContext) ___Type_inputFields(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { 1873 | defer func() { 1874 | if r := recover(); r != nil { 1875 | ec.Error(ctx, ec.Recover(ctx, r)) 1876 | ret = graphql.Null 1877 | } 1878 | }() 1879 | fc := &graphql.FieldContext{ 1880 | Object: "__Type", 1881 | Field: field, 1882 | Args: nil, 1883 | IsMethod: true, 1884 | } 1885 | 1886 | ctx = graphql.WithFieldContext(ctx, fc) 1887 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1888 | ctx = rctx // use context from middleware stack in children 1889 | return obj.InputFields(), nil 1890 | }) 1891 | if err != nil { 1892 | ec.Error(ctx, err) 1893 | return graphql.Null 1894 | } 1895 | if resTmp == nil { 1896 | return graphql.Null 1897 | } 1898 | res := resTmp.([]introspection.InputValue) 1899 | fc.Result = res 1900 | return ec.marshalO__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx, field.Selections, res) 1901 | } 1902 | 1903 | func (ec *executionContext) ___Type_ofType(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { 1904 | defer func() { 1905 | if r := recover(); r != nil { 1906 | ec.Error(ctx, ec.Recover(ctx, r)) 1907 | ret = graphql.Null 1908 | } 1909 | }() 1910 | fc := &graphql.FieldContext{ 1911 | Object: "__Type", 1912 | Field: field, 1913 | Args: nil, 1914 | IsMethod: true, 1915 | } 1916 | 1917 | ctx = graphql.WithFieldContext(ctx, fc) 1918 | resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { 1919 | ctx = rctx // use context from middleware stack in children 1920 | return obj.OfType(), nil 1921 | }) 1922 | if err != nil { 1923 | ec.Error(ctx, err) 1924 | return graphql.Null 1925 | } 1926 | if resTmp == nil { 1927 | return graphql.Null 1928 | } 1929 | res := resTmp.(*introspection.Type) 1930 | fc.Result = res 1931 | return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) 1932 | } 1933 | 1934 | // endregion **************************** field.gotpl ***************************** 1935 | 1936 | // region **************************** input.gotpl ***************************** 1937 | 1938 | func (ec *executionContext) unmarshalInputLogin(ctx context.Context, obj interface{}) (model.Login, error) { 1939 | var it model.Login 1940 | var asMap = obj.(map[string]interface{}) 1941 | 1942 | for k, v := range asMap { 1943 | switch k { 1944 | case "username": 1945 | var err error 1946 | it.Username, err = ec.unmarshalNString2string(ctx, v) 1947 | if err != nil { 1948 | return it, err 1949 | } 1950 | case "password": 1951 | var err error 1952 | it.Password, err = ec.unmarshalNString2string(ctx, v) 1953 | if err != nil { 1954 | return it, err 1955 | } 1956 | } 1957 | } 1958 | 1959 | return it, nil 1960 | } 1961 | 1962 | func (ec *executionContext) unmarshalInputNewLink(ctx context.Context, obj interface{}) (model.NewLink, error) { 1963 | var it model.NewLink 1964 | var asMap = obj.(map[string]interface{}) 1965 | 1966 | for k, v := range asMap { 1967 | switch k { 1968 | case "title": 1969 | var err error 1970 | it.Title, err = ec.unmarshalNString2string(ctx, v) 1971 | if err != nil { 1972 | return it, err 1973 | } 1974 | case "address": 1975 | var err error 1976 | it.Address, err = ec.unmarshalNString2string(ctx, v) 1977 | if err != nil { 1978 | return it, err 1979 | } 1980 | } 1981 | } 1982 | 1983 | return it, nil 1984 | } 1985 | 1986 | func (ec *executionContext) unmarshalInputNewUser(ctx context.Context, obj interface{}) (model.NewUser, error) { 1987 | var it model.NewUser 1988 | var asMap = obj.(map[string]interface{}) 1989 | 1990 | for k, v := range asMap { 1991 | switch k { 1992 | case "username": 1993 | var err error 1994 | it.Username, err = ec.unmarshalNString2string(ctx, v) 1995 | if err != nil { 1996 | return it, err 1997 | } 1998 | case "password": 1999 | var err error 2000 | it.Password, err = ec.unmarshalNString2string(ctx, v) 2001 | if err != nil { 2002 | return it, err 2003 | } 2004 | } 2005 | } 2006 | 2007 | return it, nil 2008 | } 2009 | 2010 | func (ec *executionContext) unmarshalInputRefreshTokenInput(ctx context.Context, obj interface{}) (model.RefreshTokenInput, error) { 2011 | var it model.RefreshTokenInput 2012 | var asMap = obj.(map[string]interface{}) 2013 | 2014 | for k, v := range asMap { 2015 | switch k { 2016 | case "token": 2017 | var err error 2018 | it.Token, err = ec.unmarshalNString2string(ctx, v) 2019 | if err != nil { 2020 | return it, err 2021 | } 2022 | } 2023 | } 2024 | 2025 | return it, nil 2026 | } 2027 | 2028 | // endregion **************************** input.gotpl ***************************** 2029 | 2030 | // region ************************** interface.gotpl *************************** 2031 | 2032 | // endregion ************************** interface.gotpl *************************** 2033 | 2034 | // region **************************** object.gotpl **************************** 2035 | 2036 | var linkImplementors = []string{"Link"} 2037 | 2038 | func (ec *executionContext) _Link(ctx context.Context, sel ast.SelectionSet, obj *model.Link) graphql.Marshaler { 2039 | fields := graphql.CollectFields(ec.OperationContext, sel, linkImplementors) 2040 | 2041 | out := graphql.NewFieldSet(fields) 2042 | var invalids uint32 2043 | for i, field := range fields { 2044 | switch field.Name { 2045 | case "__typename": 2046 | out.Values[i] = graphql.MarshalString("Link") 2047 | case "id": 2048 | out.Values[i] = ec._Link_id(ctx, field, obj) 2049 | if out.Values[i] == graphql.Null { 2050 | invalids++ 2051 | } 2052 | case "title": 2053 | out.Values[i] = ec._Link_title(ctx, field, obj) 2054 | if out.Values[i] == graphql.Null { 2055 | invalids++ 2056 | } 2057 | case "address": 2058 | out.Values[i] = ec._Link_address(ctx, field, obj) 2059 | if out.Values[i] == graphql.Null { 2060 | invalids++ 2061 | } 2062 | case "user": 2063 | out.Values[i] = ec._Link_user(ctx, field, obj) 2064 | if out.Values[i] == graphql.Null { 2065 | invalids++ 2066 | } 2067 | default: 2068 | panic("unknown field " + strconv.Quote(field.Name)) 2069 | } 2070 | } 2071 | out.Dispatch() 2072 | if invalids > 0 { 2073 | return graphql.Null 2074 | } 2075 | return out 2076 | } 2077 | 2078 | var mutationImplementors = []string{"Mutation"} 2079 | 2080 | func (ec *executionContext) _Mutation(ctx context.Context, sel ast.SelectionSet) graphql.Marshaler { 2081 | fields := graphql.CollectFields(ec.OperationContext, sel, mutationImplementors) 2082 | 2083 | ctx = graphql.WithFieldContext(ctx, &graphql.FieldContext{ 2084 | Object: "Mutation", 2085 | }) 2086 | 2087 | out := graphql.NewFieldSet(fields) 2088 | var invalids uint32 2089 | for i, field := range fields { 2090 | switch field.Name { 2091 | case "__typename": 2092 | out.Values[i] = graphql.MarshalString("Mutation") 2093 | case "createLink": 2094 | out.Values[i] = ec._Mutation_createLink(ctx, field) 2095 | if out.Values[i] == graphql.Null { 2096 | invalids++ 2097 | } 2098 | case "createUser": 2099 | out.Values[i] = ec._Mutation_createUser(ctx, field) 2100 | if out.Values[i] == graphql.Null { 2101 | invalids++ 2102 | } 2103 | case "login": 2104 | out.Values[i] = ec._Mutation_login(ctx, field) 2105 | if out.Values[i] == graphql.Null { 2106 | invalids++ 2107 | } 2108 | case "refreshToken": 2109 | out.Values[i] = ec._Mutation_refreshToken(ctx, field) 2110 | if out.Values[i] == graphql.Null { 2111 | invalids++ 2112 | } 2113 | default: 2114 | panic("unknown field " + strconv.Quote(field.Name)) 2115 | } 2116 | } 2117 | out.Dispatch() 2118 | if invalids > 0 { 2119 | return graphql.Null 2120 | } 2121 | return out 2122 | } 2123 | 2124 | var queryImplementors = []string{"Query"} 2125 | 2126 | func (ec *executionContext) _Query(ctx context.Context, sel ast.SelectionSet) graphql.Marshaler { 2127 | fields := graphql.CollectFields(ec.OperationContext, sel, queryImplementors) 2128 | 2129 | ctx = graphql.WithFieldContext(ctx, &graphql.FieldContext{ 2130 | Object: "Query", 2131 | }) 2132 | 2133 | out := graphql.NewFieldSet(fields) 2134 | var invalids uint32 2135 | for i, field := range fields { 2136 | switch field.Name { 2137 | case "__typename": 2138 | out.Values[i] = graphql.MarshalString("Query") 2139 | case "links": 2140 | field := field 2141 | out.Concurrently(i, func() (res graphql.Marshaler) { 2142 | defer func() { 2143 | if r := recover(); r != nil { 2144 | ec.Error(ctx, ec.Recover(ctx, r)) 2145 | } 2146 | }() 2147 | res = ec._Query_links(ctx, field) 2148 | if res == graphql.Null { 2149 | atomic.AddUint32(&invalids, 1) 2150 | } 2151 | return res 2152 | }) 2153 | case "__type": 2154 | out.Values[i] = ec._Query___type(ctx, field) 2155 | case "__schema": 2156 | out.Values[i] = ec._Query___schema(ctx, field) 2157 | default: 2158 | panic("unknown field " + strconv.Quote(field.Name)) 2159 | } 2160 | } 2161 | out.Dispatch() 2162 | if invalids > 0 { 2163 | return graphql.Null 2164 | } 2165 | return out 2166 | } 2167 | 2168 | var userImplementors = []string{"User"} 2169 | 2170 | func (ec *executionContext) _User(ctx context.Context, sel ast.SelectionSet, obj *model.User) graphql.Marshaler { 2171 | fields := graphql.CollectFields(ec.OperationContext, sel, userImplementors) 2172 | 2173 | out := graphql.NewFieldSet(fields) 2174 | var invalids uint32 2175 | for i, field := range fields { 2176 | switch field.Name { 2177 | case "__typename": 2178 | out.Values[i] = graphql.MarshalString("User") 2179 | case "id": 2180 | out.Values[i] = ec._User_id(ctx, field, obj) 2181 | if out.Values[i] == graphql.Null { 2182 | invalids++ 2183 | } 2184 | case "name": 2185 | out.Values[i] = ec._User_name(ctx, field, obj) 2186 | if out.Values[i] == graphql.Null { 2187 | invalids++ 2188 | } 2189 | default: 2190 | panic("unknown field " + strconv.Quote(field.Name)) 2191 | } 2192 | } 2193 | out.Dispatch() 2194 | if invalids > 0 { 2195 | return graphql.Null 2196 | } 2197 | return out 2198 | } 2199 | 2200 | var __DirectiveImplementors = []string{"__Directive"} 2201 | 2202 | func (ec *executionContext) ___Directive(ctx context.Context, sel ast.SelectionSet, obj *introspection.Directive) graphql.Marshaler { 2203 | fields := graphql.CollectFields(ec.OperationContext, sel, __DirectiveImplementors) 2204 | 2205 | out := graphql.NewFieldSet(fields) 2206 | var invalids uint32 2207 | for i, field := range fields { 2208 | switch field.Name { 2209 | case "__typename": 2210 | out.Values[i] = graphql.MarshalString("__Directive") 2211 | case "name": 2212 | out.Values[i] = ec.___Directive_name(ctx, field, obj) 2213 | if out.Values[i] == graphql.Null { 2214 | invalids++ 2215 | } 2216 | case "description": 2217 | out.Values[i] = ec.___Directive_description(ctx, field, obj) 2218 | case "locations": 2219 | out.Values[i] = ec.___Directive_locations(ctx, field, obj) 2220 | if out.Values[i] == graphql.Null { 2221 | invalids++ 2222 | } 2223 | case "args": 2224 | out.Values[i] = ec.___Directive_args(ctx, field, obj) 2225 | if out.Values[i] == graphql.Null { 2226 | invalids++ 2227 | } 2228 | default: 2229 | panic("unknown field " + strconv.Quote(field.Name)) 2230 | } 2231 | } 2232 | out.Dispatch() 2233 | if invalids > 0 { 2234 | return graphql.Null 2235 | } 2236 | return out 2237 | } 2238 | 2239 | var __EnumValueImplementors = []string{"__EnumValue"} 2240 | 2241 | func (ec *executionContext) ___EnumValue(ctx context.Context, sel ast.SelectionSet, obj *introspection.EnumValue) graphql.Marshaler { 2242 | fields := graphql.CollectFields(ec.OperationContext, sel, __EnumValueImplementors) 2243 | 2244 | out := graphql.NewFieldSet(fields) 2245 | var invalids uint32 2246 | for i, field := range fields { 2247 | switch field.Name { 2248 | case "__typename": 2249 | out.Values[i] = graphql.MarshalString("__EnumValue") 2250 | case "name": 2251 | out.Values[i] = ec.___EnumValue_name(ctx, field, obj) 2252 | if out.Values[i] == graphql.Null { 2253 | invalids++ 2254 | } 2255 | case "description": 2256 | out.Values[i] = ec.___EnumValue_description(ctx, field, obj) 2257 | case "isDeprecated": 2258 | out.Values[i] = ec.___EnumValue_isDeprecated(ctx, field, obj) 2259 | if out.Values[i] == graphql.Null { 2260 | invalids++ 2261 | } 2262 | case "deprecationReason": 2263 | out.Values[i] = ec.___EnumValue_deprecationReason(ctx, field, obj) 2264 | default: 2265 | panic("unknown field " + strconv.Quote(field.Name)) 2266 | } 2267 | } 2268 | out.Dispatch() 2269 | if invalids > 0 { 2270 | return graphql.Null 2271 | } 2272 | return out 2273 | } 2274 | 2275 | var __FieldImplementors = []string{"__Field"} 2276 | 2277 | func (ec *executionContext) ___Field(ctx context.Context, sel ast.SelectionSet, obj *introspection.Field) graphql.Marshaler { 2278 | fields := graphql.CollectFields(ec.OperationContext, sel, __FieldImplementors) 2279 | 2280 | out := graphql.NewFieldSet(fields) 2281 | var invalids uint32 2282 | for i, field := range fields { 2283 | switch field.Name { 2284 | case "__typename": 2285 | out.Values[i] = graphql.MarshalString("__Field") 2286 | case "name": 2287 | out.Values[i] = ec.___Field_name(ctx, field, obj) 2288 | if out.Values[i] == graphql.Null { 2289 | invalids++ 2290 | } 2291 | case "description": 2292 | out.Values[i] = ec.___Field_description(ctx, field, obj) 2293 | case "args": 2294 | out.Values[i] = ec.___Field_args(ctx, field, obj) 2295 | if out.Values[i] == graphql.Null { 2296 | invalids++ 2297 | } 2298 | case "type": 2299 | out.Values[i] = ec.___Field_type(ctx, field, obj) 2300 | if out.Values[i] == graphql.Null { 2301 | invalids++ 2302 | } 2303 | case "isDeprecated": 2304 | out.Values[i] = ec.___Field_isDeprecated(ctx, field, obj) 2305 | if out.Values[i] == graphql.Null { 2306 | invalids++ 2307 | } 2308 | case "deprecationReason": 2309 | out.Values[i] = ec.___Field_deprecationReason(ctx, field, obj) 2310 | default: 2311 | panic("unknown field " + strconv.Quote(field.Name)) 2312 | } 2313 | } 2314 | out.Dispatch() 2315 | if invalids > 0 { 2316 | return graphql.Null 2317 | } 2318 | return out 2319 | } 2320 | 2321 | var __InputValueImplementors = []string{"__InputValue"} 2322 | 2323 | func (ec *executionContext) ___InputValue(ctx context.Context, sel ast.SelectionSet, obj *introspection.InputValue) graphql.Marshaler { 2324 | fields := graphql.CollectFields(ec.OperationContext, sel, __InputValueImplementors) 2325 | 2326 | out := graphql.NewFieldSet(fields) 2327 | var invalids uint32 2328 | for i, field := range fields { 2329 | switch field.Name { 2330 | case "__typename": 2331 | out.Values[i] = graphql.MarshalString("__InputValue") 2332 | case "name": 2333 | out.Values[i] = ec.___InputValue_name(ctx, field, obj) 2334 | if out.Values[i] == graphql.Null { 2335 | invalids++ 2336 | } 2337 | case "description": 2338 | out.Values[i] = ec.___InputValue_description(ctx, field, obj) 2339 | case "type": 2340 | out.Values[i] = ec.___InputValue_type(ctx, field, obj) 2341 | if out.Values[i] == graphql.Null { 2342 | invalids++ 2343 | } 2344 | case "defaultValue": 2345 | out.Values[i] = ec.___InputValue_defaultValue(ctx, field, obj) 2346 | default: 2347 | panic("unknown field " + strconv.Quote(field.Name)) 2348 | } 2349 | } 2350 | out.Dispatch() 2351 | if invalids > 0 { 2352 | return graphql.Null 2353 | } 2354 | return out 2355 | } 2356 | 2357 | var __SchemaImplementors = []string{"__Schema"} 2358 | 2359 | func (ec *executionContext) ___Schema(ctx context.Context, sel ast.SelectionSet, obj *introspection.Schema) graphql.Marshaler { 2360 | fields := graphql.CollectFields(ec.OperationContext, sel, __SchemaImplementors) 2361 | 2362 | out := graphql.NewFieldSet(fields) 2363 | var invalids uint32 2364 | for i, field := range fields { 2365 | switch field.Name { 2366 | case "__typename": 2367 | out.Values[i] = graphql.MarshalString("__Schema") 2368 | case "types": 2369 | out.Values[i] = ec.___Schema_types(ctx, field, obj) 2370 | if out.Values[i] == graphql.Null { 2371 | invalids++ 2372 | } 2373 | case "queryType": 2374 | out.Values[i] = ec.___Schema_queryType(ctx, field, obj) 2375 | if out.Values[i] == graphql.Null { 2376 | invalids++ 2377 | } 2378 | case "mutationType": 2379 | out.Values[i] = ec.___Schema_mutationType(ctx, field, obj) 2380 | case "subscriptionType": 2381 | out.Values[i] = ec.___Schema_subscriptionType(ctx, field, obj) 2382 | case "directives": 2383 | out.Values[i] = ec.___Schema_directives(ctx, field, obj) 2384 | if out.Values[i] == graphql.Null { 2385 | invalids++ 2386 | } 2387 | default: 2388 | panic("unknown field " + strconv.Quote(field.Name)) 2389 | } 2390 | } 2391 | out.Dispatch() 2392 | if invalids > 0 { 2393 | return graphql.Null 2394 | } 2395 | return out 2396 | } 2397 | 2398 | var __TypeImplementors = []string{"__Type"} 2399 | 2400 | func (ec *executionContext) ___Type(ctx context.Context, sel ast.SelectionSet, obj *introspection.Type) graphql.Marshaler { 2401 | fields := graphql.CollectFields(ec.OperationContext, sel, __TypeImplementors) 2402 | 2403 | out := graphql.NewFieldSet(fields) 2404 | var invalids uint32 2405 | for i, field := range fields { 2406 | switch field.Name { 2407 | case "__typename": 2408 | out.Values[i] = graphql.MarshalString("__Type") 2409 | case "kind": 2410 | out.Values[i] = ec.___Type_kind(ctx, field, obj) 2411 | if out.Values[i] == graphql.Null { 2412 | invalids++ 2413 | } 2414 | case "name": 2415 | out.Values[i] = ec.___Type_name(ctx, field, obj) 2416 | case "description": 2417 | out.Values[i] = ec.___Type_description(ctx, field, obj) 2418 | case "fields": 2419 | out.Values[i] = ec.___Type_fields(ctx, field, obj) 2420 | case "interfaces": 2421 | out.Values[i] = ec.___Type_interfaces(ctx, field, obj) 2422 | case "possibleTypes": 2423 | out.Values[i] = ec.___Type_possibleTypes(ctx, field, obj) 2424 | case "enumValues": 2425 | out.Values[i] = ec.___Type_enumValues(ctx, field, obj) 2426 | case "inputFields": 2427 | out.Values[i] = ec.___Type_inputFields(ctx, field, obj) 2428 | case "ofType": 2429 | out.Values[i] = ec.___Type_ofType(ctx, field, obj) 2430 | default: 2431 | panic("unknown field " + strconv.Quote(field.Name)) 2432 | } 2433 | } 2434 | out.Dispatch() 2435 | if invalids > 0 { 2436 | return graphql.Null 2437 | } 2438 | return out 2439 | } 2440 | 2441 | // endregion **************************** object.gotpl **************************** 2442 | 2443 | // region ***************************** type.gotpl ***************************** 2444 | 2445 | func (ec *executionContext) unmarshalNBoolean2bool(ctx context.Context, v interface{}) (bool, error) { 2446 | return graphql.UnmarshalBoolean(v) 2447 | } 2448 | 2449 | func (ec *executionContext) marshalNBoolean2bool(ctx context.Context, sel ast.SelectionSet, v bool) graphql.Marshaler { 2450 | res := graphql.MarshalBoolean(v) 2451 | if res == graphql.Null { 2452 | if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 2453 | ec.Errorf(ctx, "must not be null") 2454 | } 2455 | } 2456 | return res 2457 | } 2458 | 2459 | func (ec *executionContext) unmarshalNID2string(ctx context.Context, v interface{}) (string, error) { 2460 | return graphql.UnmarshalID(v) 2461 | } 2462 | 2463 | func (ec *executionContext) marshalNID2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler { 2464 | res := graphql.MarshalID(v) 2465 | if res == graphql.Null { 2466 | if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 2467 | ec.Errorf(ctx, "must not be null") 2468 | } 2469 | } 2470 | return res 2471 | } 2472 | 2473 | func (ec *executionContext) marshalNLink2githubᚗcomᚋglyphackᚋgraphlqᚑgolangᚋgraphᚋmodelᚐLink(ctx context.Context, sel ast.SelectionSet, v model.Link) graphql.Marshaler { 2474 | return ec._Link(ctx, sel, &v) 2475 | } 2476 | 2477 | func (ec *executionContext) marshalNLink2ᚕᚖgithubᚗcomᚋglyphackᚋgraphlqᚑgolangᚋgraphᚋmodelᚐLinkᚄ(ctx context.Context, sel ast.SelectionSet, v []*model.Link) graphql.Marshaler { 2478 | ret := make(graphql.Array, len(v)) 2479 | var wg sync.WaitGroup 2480 | isLen1 := len(v) == 1 2481 | if !isLen1 { 2482 | wg.Add(len(v)) 2483 | } 2484 | for i := range v { 2485 | i := i 2486 | fc := &graphql.FieldContext{ 2487 | Index: &i, 2488 | Result: &v[i], 2489 | } 2490 | ctx := graphql.WithFieldContext(ctx, fc) 2491 | f := func(i int) { 2492 | defer func() { 2493 | if r := recover(); r != nil { 2494 | ec.Error(ctx, ec.Recover(ctx, r)) 2495 | ret = nil 2496 | } 2497 | }() 2498 | if !isLen1 { 2499 | defer wg.Done() 2500 | } 2501 | ret[i] = ec.marshalNLink2ᚖgithubᚗcomᚋglyphackᚋgraphlqᚑgolangᚋgraphᚋmodelᚐLink(ctx, sel, v[i]) 2502 | } 2503 | if isLen1 { 2504 | f(i) 2505 | } else { 2506 | go f(i) 2507 | } 2508 | 2509 | } 2510 | wg.Wait() 2511 | return ret 2512 | } 2513 | 2514 | func (ec *executionContext) marshalNLink2ᚖgithubᚗcomᚋglyphackᚋgraphlqᚑgolangᚋgraphᚋmodelᚐLink(ctx context.Context, sel ast.SelectionSet, v *model.Link) graphql.Marshaler { 2515 | if v == nil { 2516 | if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 2517 | ec.Errorf(ctx, "must not be null") 2518 | } 2519 | return graphql.Null 2520 | } 2521 | return ec._Link(ctx, sel, v) 2522 | } 2523 | 2524 | func (ec *executionContext) unmarshalNLogin2githubᚗcomᚋglyphackᚋgraphlqᚑgolangᚋgraphᚋmodelᚐLogin(ctx context.Context, v interface{}) (model.Login, error) { 2525 | return ec.unmarshalInputLogin(ctx, v) 2526 | } 2527 | 2528 | func (ec *executionContext) unmarshalNNewLink2githubᚗcomᚋglyphackᚋgraphlqᚑgolangᚋgraphᚋmodelᚐNewLink(ctx context.Context, v interface{}) (model.NewLink, error) { 2529 | return ec.unmarshalInputNewLink(ctx, v) 2530 | } 2531 | 2532 | func (ec *executionContext) unmarshalNNewUser2githubᚗcomᚋglyphackᚋgraphlqᚑgolangᚋgraphᚋmodelᚐNewUser(ctx context.Context, v interface{}) (model.NewUser, error) { 2533 | return ec.unmarshalInputNewUser(ctx, v) 2534 | } 2535 | 2536 | func (ec *executionContext) unmarshalNRefreshTokenInput2githubᚗcomᚋglyphackᚋgraphlqᚑgolangᚋgraphᚋmodelᚐRefreshTokenInput(ctx context.Context, v interface{}) (model.RefreshTokenInput, error) { 2537 | return ec.unmarshalInputRefreshTokenInput(ctx, v) 2538 | } 2539 | 2540 | func (ec *executionContext) unmarshalNString2string(ctx context.Context, v interface{}) (string, error) { 2541 | return graphql.UnmarshalString(v) 2542 | } 2543 | 2544 | func (ec *executionContext) marshalNString2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler { 2545 | res := graphql.MarshalString(v) 2546 | if res == graphql.Null { 2547 | if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 2548 | ec.Errorf(ctx, "must not be null") 2549 | } 2550 | } 2551 | return res 2552 | } 2553 | 2554 | func (ec *executionContext) marshalNUser2githubᚗcomᚋglyphackᚋgraphlqᚑgolangᚋgraphᚋmodelᚐUser(ctx context.Context, sel ast.SelectionSet, v model.User) graphql.Marshaler { 2555 | return ec._User(ctx, sel, &v) 2556 | } 2557 | 2558 | func (ec *executionContext) marshalNUser2ᚖgithubᚗcomᚋglyphackᚋgraphlqᚑgolangᚋgraphᚋmodelᚐUser(ctx context.Context, sel ast.SelectionSet, v *model.User) graphql.Marshaler { 2559 | if v == nil { 2560 | if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 2561 | ec.Errorf(ctx, "must not be null") 2562 | } 2563 | return graphql.Null 2564 | } 2565 | return ec._User(ctx, sel, v) 2566 | } 2567 | 2568 | func (ec *executionContext) marshalN__Directive2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirective(ctx context.Context, sel ast.SelectionSet, v introspection.Directive) graphql.Marshaler { 2569 | return ec.___Directive(ctx, sel, &v) 2570 | } 2571 | 2572 | func (ec *executionContext) marshalN__Directive2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirectiveᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Directive) graphql.Marshaler { 2573 | ret := make(graphql.Array, len(v)) 2574 | var wg sync.WaitGroup 2575 | isLen1 := len(v) == 1 2576 | if !isLen1 { 2577 | wg.Add(len(v)) 2578 | } 2579 | for i := range v { 2580 | i := i 2581 | fc := &graphql.FieldContext{ 2582 | Index: &i, 2583 | Result: &v[i], 2584 | } 2585 | ctx := graphql.WithFieldContext(ctx, fc) 2586 | f := func(i int) { 2587 | defer func() { 2588 | if r := recover(); r != nil { 2589 | ec.Error(ctx, ec.Recover(ctx, r)) 2590 | ret = nil 2591 | } 2592 | }() 2593 | if !isLen1 { 2594 | defer wg.Done() 2595 | } 2596 | ret[i] = ec.marshalN__Directive2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirective(ctx, sel, v[i]) 2597 | } 2598 | if isLen1 { 2599 | f(i) 2600 | } else { 2601 | go f(i) 2602 | } 2603 | 2604 | } 2605 | wg.Wait() 2606 | return ret 2607 | } 2608 | 2609 | func (ec *executionContext) unmarshalN__DirectiveLocation2string(ctx context.Context, v interface{}) (string, error) { 2610 | return graphql.UnmarshalString(v) 2611 | } 2612 | 2613 | func (ec *executionContext) marshalN__DirectiveLocation2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler { 2614 | res := graphql.MarshalString(v) 2615 | if res == graphql.Null { 2616 | if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 2617 | ec.Errorf(ctx, "must not be null") 2618 | } 2619 | } 2620 | return res 2621 | } 2622 | 2623 | func (ec *executionContext) unmarshalN__DirectiveLocation2ᚕstringᚄ(ctx context.Context, v interface{}) ([]string, error) { 2624 | var vSlice []interface{} 2625 | if v != nil { 2626 | if tmp1, ok := v.([]interface{}); ok { 2627 | vSlice = tmp1 2628 | } else { 2629 | vSlice = []interface{}{v} 2630 | } 2631 | } 2632 | var err error 2633 | res := make([]string, len(vSlice)) 2634 | for i := range vSlice { 2635 | res[i], err = ec.unmarshalN__DirectiveLocation2string(ctx, vSlice[i]) 2636 | if err != nil { 2637 | return nil, err 2638 | } 2639 | } 2640 | return res, nil 2641 | } 2642 | 2643 | func (ec *executionContext) marshalN__DirectiveLocation2ᚕstringᚄ(ctx context.Context, sel ast.SelectionSet, v []string) graphql.Marshaler { 2644 | ret := make(graphql.Array, len(v)) 2645 | var wg sync.WaitGroup 2646 | isLen1 := len(v) == 1 2647 | if !isLen1 { 2648 | wg.Add(len(v)) 2649 | } 2650 | for i := range v { 2651 | i := i 2652 | fc := &graphql.FieldContext{ 2653 | Index: &i, 2654 | Result: &v[i], 2655 | } 2656 | ctx := graphql.WithFieldContext(ctx, fc) 2657 | f := func(i int) { 2658 | defer func() { 2659 | if r := recover(); r != nil { 2660 | ec.Error(ctx, ec.Recover(ctx, r)) 2661 | ret = nil 2662 | } 2663 | }() 2664 | if !isLen1 { 2665 | defer wg.Done() 2666 | } 2667 | ret[i] = ec.marshalN__DirectiveLocation2string(ctx, sel, v[i]) 2668 | } 2669 | if isLen1 { 2670 | f(i) 2671 | } else { 2672 | go f(i) 2673 | } 2674 | 2675 | } 2676 | wg.Wait() 2677 | return ret 2678 | } 2679 | 2680 | func (ec *executionContext) marshalN__EnumValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValue(ctx context.Context, sel ast.SelectionSet, v introspection.EnumValue) graphql.Marshaler { 2681 | return ec.___EnumValue(ctx, sel, &v) 2682 | } 2683 | 2684 | func (ec *executionContext) marshalN__Field2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐField(ctx context.Context, sel ast.SelectionSet, v introspection.Field) graphql.Marshaler { 2685 | return ec.___Field(ctx, sel, &v) 2686 | } 2687 | 2688 | func (ec *executionContext) marshalN__InputValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx context.Context, sel ast.SelectionSet, v introspection.InputValue) graphql.Marshaler { 2689 | return ec.___InputValue(ctx, sel, &v) 2690 | } 2691 | 2692 | func (ec *executionContext) marshalN__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.InputValue) graphql.Marshaler { 2693 | ret := make(graphql.Array, len(v)) 2694 | var wg sync.WaitGroup 2695 | isLen1 := len(v) == 1 2696 | if !isLen1 { 2697 | wg.Add(len(v)) 2698 | } 2699 | for i := range v { 2700 | i := i 2701 | fc := &graphql.FieldContext{ 2702 | Index: &i, 2703 | Result: &v[i], 2704 | } 2705 | ctx := graphql.WithFieldContext(ctx, fc) 2706 | f := func(i int) { 2707 | defer func() { 2708 | if r := recover(); r != nil { 2709 | ec.Error(ctx, ec.Recover(ctx, r)) 2710 | ret = nil 2711 | } 2712 | }() 2713 | if !isLen1 { 2714 | defer wg.Done() 2715 | } 2716 | ret[i] = ec.marshalN__InputValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx, sel, v[i]) 2717 | } 2718 | if isLen1 { 2719 | f(i) 2720 | } else { 2721 | go f(i) 2722 | } 2723 | 2724 | } 2725 | wg.Wait() 2726 | return ret 2727 | } 2728 | 2729 | func (ec *executionContext) marshalN__Type2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v introspection.Type) graphql.Marshaler { 2730 | return ec.___Type(ctx, sel, &v) 2731 | } 2732 | 2733 | func (ec *executionContext) marshalN__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Type) graphql.Marshaler { 2734 | ret := make(graphql.Array, len(v)) 2735 | var wg sync.WaitGroup 2736 | isLen1 := len(v) == 1 2737 | if !isLen1 { 2738 | wg.Add(len(v)) 2739 | } 2740 | for i := range v { 2741 | i := i 2742 | fc := &graphql.FieldContext{ 2743 | Index: &i, 2744 | Result: &v[i], 2745 | } 2746 | ctx := graphql.WithFieldContext(ctx, fc) 2747 | f := func(i int) { 2748 | defer func() { 2749 | if r := recover(); r != nil { 2750 | ec.Error(ctx, ec.Recover(ctx, r)) 2751 | ret = nil 2752 | } 2753 | }() 2754 | if !isLen1 { 2755 | defer wg.Done() 2756 | } 2757 | ret[i] = ec.marshalN__Type2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, sel, v[i]) 2758 | } 2759 | if isLen1 { 2760 | f(i) 2761 | } else { 2762 | go f(i) 2763 | } 2764 | 2765 | } 2766 | wg.Wait() 2767 | return ret 2768 | } 2769 | 2770 | func (ec *executionContext) marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v *introspection.Type) graphql.Marshaler { 2771 | if v == nil { 2772 | if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 2773 | ec.Errorf(ctx, "must not be null") 2774 | } 2775 | return graphql.Null 2776 | } 2777 | return ec.___Type(ctx, sel, v) 2778 | } 2779 | 2780 | func (ec *executionContext) unmarshalN__TypeKind2string(ctx context.Context, v interface{}) (string, error) { 2781 | return graphql.UnmarshalString(v) 2782 | } 2783 | 2784 | func (ec *executionContext) marshalN__TypeKind2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler { 2785 | res := graphql.MarshalString(v) 2786 | if res == graphql.Null { 2787 | if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { 2788 | ec.Errorf(ctx, "must not be null") 2789 | } 2790 | } 2791 | return res 2792 | } 2793 | 2794 | func (ec *executionContext) unmarshalOBoolean2bool(ctx context.Context, v interface{}) (bool, error) { 2795 | return graphql.UnmarshalBoolean(v) 2796 | } 2797 | 2798 | func (ec *executionContext) marshalOBoolean2bool(ctx context.Context, sel ast.SelectionSet, v bool) graphql.Marshaler { 2799 | return graphql.MarshalBoolean(v) 2800 | } 2801 | 2802 | func (ec *executionContext) unmarshalOBoolean2ᚖbool(ctx context.Context, v interface{}) (*bool, error) { 2803 | if v == nil { 2804 | return nil, nil 2805 | } 2806 | res, err := ec.unmarshalOBoolean2bool(ctx, v) 2807 | return &res, err 2808 | } 2809 | 2810 | func (ec *executionContext) marshalOBoolean2ᚖbool(ctx context.Context, sel ast.SelectionSet, v *bool) graphql.Marshaler { 2811 | if v == nil { 2812 | return graphql.Null 2813 | } 2814 | return ec.marshalOBoolean2bool(ctx, sel, *v) 2815 | } 2816 | 2817 | func (ec *executionContext) unmarshalOString2string(ctx context.Context, v interface{}) (string, error) { 2818 | return graphql.UnmarshalString(v) 2819 | } 2820 | 2821 | func (ec *executionContext) marshalOString2string(ctx context.Context, sel ast.SelectionSet, v string) graphql.Marshaler { 2822 | return graphql.MarshalString(v) 2823 | } 2824 | 2825 | func (ec *executionContext) unmarshalOString2ᚖstring(ctx context.Context, v interface{}) (*string, error) { 2826 | if v == nil { 2827 | return nil, nil 2828 | } 2829 | res, err := ec.unmarshalOString2string(ctx, v) 2830 | return &res, err 2831 | } 2832 | 2833 | func (ec *executionContext) marshalOString2ᚖstring(ctx context.Context, sel ast.SelectionSet, v *string) graphql.Marshaler { 2834 | if v == nil { 2835 | return graphql.Null 2836 | } 2837 | return ec.marshalOString2string(ctx, sel, *v) 2838 | } 2839 | 2840 | func (ec *executionContext) marshalO__EnumValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValueᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.EnumValue) graphql.Marshaler { 2841 | if v == nil { 2842 | return graphql.Null 2843 | } 2844 | ret := make(graphql.Array, len(v)) 2845 | var wg sync.WaitGroup 2846 | isLen1 := len(v) == 1 2847 | if !isLen1 { 2848 | wg.Add(len(v)) 2849 | } 2850 | for i := range v { 2851 | i := i 2852 | fc := &graphql.FieldContext{ 2853 | Index: &i, 2854 | Result: &v[i], 2855 | } 2856 | ctx := graphql.WithFieldContext(ctx, fc) 2857 | f := func(i int) { 2858 | defer func() { 2859 | if r := recover(); r != nil { 2860 | ec.Error(ctx, ec.Recover(ctx, r)) 2861 | ret = nil 2862 | } 2863 | }() 2864 | if !isLen1 { 2865 | defer wg.Done() 2866 | } 2867 | ret[i] = ec.marshalN__EnumValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValue(ctx, sel, v[i]) 2868 | } 2869 | if isLen1 { 2870 | f(i) 2871 | } else { 2872 | go f(i) 2873 | } 2874 | 2875 | } 2876 | wg.Wait() 2877 | return ret 2878 | } 2879 | 2880 | func (ec *executionContext) marshalO__Field2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐFieldᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Field) graphql.Marshaler { 2881 | if v == nil { 2882 | return graphql.Null 2883 | } 2884 | ret := make(graphql.Array, len(v)) 2885 | var wg sync.WaitGroup 2886 | isLen1 := len(v) == 1 2887 | if !isLen1 { 2888 | wg.Add(len(v)) 2889 | } 2890 | for i := range v { 2891 | i := i 2892 | fc := &graphql.FieldContext{ 2893 | Index: &i, 2894 | Result: &v[i], 2895 | } 2896 | ctx := graphql.WithFieldContext(ctx, fc) 2897 | f := func(i int) { 2898 | defer func() { 2899 | if r := recover(); r != nil { 2900 | ec.Error(ctx, ec.Recover(ctx, r)) 2901 | ret = nil 2902 | } 2903 | }() 2904 | if !isLen1 { 2905 | defer wg.Done() 2906 | } 2907 | ret[i] = ec.marshalN__Field2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐField(ctx, sel, v[i]) 2908 | } 2909 | if isLen1 { 2910 | f(i) 2911 | } else { 2912 | go f(i) 2913 | } 2914 | 2915 | } 2916 | wg.Wait() 2917 | return ret 2918 | } 2919 | 2920 | func (ec *executionContext) marshalO__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.InputValue) graphql.Marshaler { 2921 | if v == nil { 2922 | return graphql.Null 2923 | } 2924 | ret := make(graphql.Array, len(v)) 2925 | var wg sync.WaitGroup 2926 | isLen1 := len(v) == 1 2927 | if !isLen1 { 2928 | wg.Add(len(v)) 2929 | } 2930 | for i := range v { 2931 | i := i 2932 | fc := &graphql.FieldContext{ 2933 | Index: &i, 2934 | Result: &v[i], 2935 | } 2936 | ctx := graphql.WithFieldContext(ctx, fc) 2937 | f := func(i int) { 2938 | defer func() { 2939 | if r := recover(); r != nil { 2940 | ec.Error(ctx, ec.Recover(ctx, r)) 2941 | ret = nil 2942 | } 2943 | }() 2944 | if !isLen1 { 2945 | defer wg.Done() 2946 | } 2947 | ret[i] = ec.marshalN__InputValue2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValue(ctx, sel, v[i]) 2948 | } 2949 | if isLen1 { 2950 | f(i) 2951 | } else { 2952 | go f(i) 2953 | } 2954 | 2955 | } 2956 | wg.Wait() 2957 | return ret 2958 | } 2959 | 2960 | func (ec *executionContext) marshalO__Schema2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐSchema(ctx context.Context, sel ast.SelectionSet, v introspection.Schema) graphql.Marshaler { 2961 | return ec.___Schema(ctx, sel, &v) 2962 | } 2963 | 2964 | func (ec *executionContext) marshalO__Schema2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐSchema(ctx context.Context, sel ast.SelectionSet, v *introspection.Schema) graphql.Marshaler { 2965 | if v == nil { 2966 | return graphql.Null 2967 | } 2968 | return ec.___Schema(ctx, sel, v) 2969 | } 2970 | 2971 | func (ec *executionContext) marshalO__Type2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v introspection.Type) graphql.Marshaler { 2972 | return ec.___Type(ctx, sel, &v) 2973 | } 2974 | 2975 | func (ec *executionContext) marshalO__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx context.Context, sel ast.SelectionSet, v []introspection.Type) graphql.Marshaler { 2976 | if v == nil { 2977 | return graphql.Null 2978 | } 2979 | ret := make(graphql.Array, len(v)) 2980 | var wg sync.WaitGroup 2981 | isLen1 := len(v) == 1 2982 | if !isLen1 { 2983 | wg.Add(len(v)) 2984 | } 2985 | for i := range v { 2986 | i := i 2987 | fc := &graphql.FieldContext{ 2988 | Index: &i, 2989 | Result: &v[i], 2990 | } 2991 | ctx := graphql.WithFieldContext(ctx, fc) 2992 | f := func(i int) { 2993 | defer func() { 2994 | if r := recover(); r != nil { 2995 | ec.Error(ctx, ec.Recover(ctx, r)) 2996 | ret = nil 2997 | } 2998 | }() 2999 | if !isLen1 { 3000 | defer wg.Done() 3001 | } 3002 | ret[i] = ec.marshalN__Type2githubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, sel, v[i]) 3003 | } 3004 | if isLen1 { 3005 | f(i) 3006 | } else { 3007 | go f(i) 3008 | } 3009 | 3010 | } 3011 | wg.Wait() 3012 | return ret 3013 | } 3014 | 3015 | func (ec *executionContext) marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v *introspection.Type) graphql.Marshaler { 3016 | if v == nil { 3017 | return graphql.Null 3018 | } 3019 | return ec.___Type(ctx, sel, v) 3020 | } 3021 | 3022 | // endregion ***************************** type.gotpl ***************************** 3023 | --------------------------------------------------------------------------------