diff --git a/go.mod b/go.mod index 584f2e2..1f32344 100644 --- a/go.mod +++ b/go.mod @@ -1,9 +1,9 @@ module github.com/satimoto/go-api -go 1.17 +go 1.18 require ( - github.com/99designs/gqlgen v0.17.2 + github.com/99designs/gqlgen v0.17.20 github.com/aws/aws-sdk-go v1.44.42 github.com/go-chi/chi v1.5.4 github.com/go-chi/chi/v5 v5.0.7 @@ -14,7 +14,7 @@ require ( github.com/joho/godotenv v1.4.0 github.com/satimoto/go-datastore v0.3.1-0.20220930074556-db0579f24964 github.com/skip2/go-qrcode v0.0.0-20200617195104-da1b6568686e - github.com/vektah/gqlparser/v2 v2.4.0 + github.com/vektah/gqlparser/v2 v2.5.1 ) require ( @@ -33,7 +33,7 @@ require ( github.com/davecgh/go-spew v1.1.1 // indirect github.com/decred/dcrd/lru v1.0.0 // indirect github.com/go-errors/errors v1.0.1 // indirect - github.com/gorilla/websocket v1.4.2 // indirect + github.com/gorilla/websocket v1.5.0 // indirect github.com/hashicorp/golang-lru v0.5.4 // indirect github.com/jmespath/go-jmespath v0.4.0 // indirect github.com/kkdai/bstream v1.0.0 // indirect @@ -50,8 +50,8 @@ require ( github.com/tidwall/match v1.0.1 // indirect github.com/tidwall/pretty v1.0.2 // indirect golang.org/x/crypto v0.0.0-20210921155107-089bfa567519 // indirect - golang.org/x/net v0.0.0-20220127200216-cd36cc0744dd // indirect - golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a // indirect + golang.org/x/net v0.0.0-20220722155237-a158d28d115b // indirect + golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab // indirect golang.org/x/term v0.0.0-20210927222741-03fcf44c2211 // indirect ) @@ -63,11 +63,11 @@ require ( github.com/prometheus/client_golang v1.12.2 github.com/satimoto/go-ferp v0.1.1-0.20220908195810-ff288d2a2a2f github.com/satimoto/go-lsp v0.2.1-0.20220919200559-6ab40df2ed28 - github.com/satimoto/go-ocpi v0.2.1-0.20220923105144-3c3054ca1740 + github.com/satimoto/go-ocpi v0.2.1-0.20221004141626-e7ce17baeb36 golang.org/x/text v0.3.7 // indirect google.golang.org/genproto v0.0.0-20210828152312-66f60bf46e71 // indirect google.golang.org/grpc v1.47.0 - google.golang.org/protobuf v1.27.1 // indirect + google.golang.org/protobuf v1.28.1 // indirect ) require ( @@ -82,18 +82,17 @@ require ( github.com/decred/dcrd/dcrec/secp256k1/v4 v4.1.0 // indirect github.com/lightningnetwork/lnd/tlv v1.0.3 // indirect github.com/lightningnetwork/lnd/tor v1.0.1 // indirect - github.com/matryer/moq v0.2.3 // indirect github.com/matttproud/golang_protobuf_extensions v1.0.1 // indirect github.com/nbd-wtf/ln-decodepay v1.5.1 // indirect github.com/prometheus/client_model v0.2.0 // indirect github.com/prometheus/common v0.32.1 // indirect github.com/prometheus/procfs v0.7.3 // indirect github.com/russross/blackfriday/v2 v2.1.0 // indirect - github.com/urfave/cli/v2 v2.3.0 // indirect - golang.org/x/mod v0.6.0-dev.0.20211013180041-c96bc1413d57 // indirect - golang.org/x/tools v0.1.9 // indirect - golang.org/x/xerrors v0.0.0-20200804184101-5ec99f83aff1 // indirect - gopkg.in/yaml.v2 v2.4.0 // indirect + github.com/urfave/cli/v2 v2.8.1 // indirect + github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 // indirect + golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4 // indirect + golang.org/x/tools v0.1.12 // indirect + gopkg.in/yaml.v3 v3.0.1 // indirect ) replace git.schwanenlied.me/yawning/bsaes.git => github.com/Yawning/bsaes v0.0.0-20180720073208-c0276d75487e diff --git a/go.sum b/go.sum index 0d85332..56a44bf 100644 --- a/go.sum +++ b/go.sum @@ -32,9 +32,10 @@ cloud.google.com/go/storage v1.6.0/go.mod h1:N7U0C8pVQ/+NIKOBQyamJIeKQKkZ+mxpohl cloud.google.com/go/storage v1.8.0/go.mod h1:Wv1Oy7z6Yz3DshWRJFhqM/UCfaWIRTdp0RXyy7KQOVs= cloud.google.com/go/storage v1.10.0/go.mod h1:FLPqc6j+Ki4BU591ie1oL6qBQGu2Bl/tZ9ullr3+Kg0= dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU= -github.com/99designs/gqlgen v0.17.2 h1:yczvlwMsfcVu/JtejqfrLwXuSP0yZFhmcss3caEvHw8= -github.com/99designs/gqlgen v0.17.2/go.mod h1:K5fzLKwtph+FFgh9j7nFbRUdBKvTcGnsta51fsMTn3o= +github.com/99designs/gqlgen v0.17.20 h1:O7WzccIhKB1dm+7g6dhQcULINftfiLSBg2l/mwbpJMw= +github.com/99designs/gqlgen v0.17.20/go.mod h1:Mja2HI23kWT1VRH09hvWshFgOzKswpO20o4ScpJIES4= github.com/BurntSushi/toml v0.3.1/go.mod h1:xHWCNGjB5oqiDr8zfno3MHue2Ht5sIBksp03qcyfWMU= +github.com/BurntSushi/toml v1.1.0/go.mod h1:CxXYINrC8qIiEnFrOxCa7Jy5BFHlXnUU2pbicEuybxQ= github.com/BurntSushi/xgb v0.0.0-20160522181843-27f122750802/go.mod h1:IVnqGOEym/WlBOVXweHU+Q+/VP0lqqI8lqeDx9IjBqo= github.com/Masterminds/semver/v3 v3.1.1/go.mod h1:VPu/7SZ7ePZ3QOrcuXROw5FAcLl4a0cBrbBpGY/8hQs= github.com/NebulousLabs/fastrand v0.0.0-20181203155948-6fb6489aac4e/go.mod h1:Bdzq+51GR4/0DIhaICZEOm+OHvXGwwB2trKZ8B4Y6eQ= @@ -46,7 +47,6 @@ github.com/aead/chacha20 v0.0.0-20180709150244-8b13a72661da/go.mod h1:eHEWzANqSi github.com/aead/siphash v1.0.1 h1:FwHfE/T45KPKYuuSAKyyvE+oPWcaQ+CUmFW0bPlM+kg= github.com/aead/siphash v1.0.1/go.mod h1:Nywa3cDsYNNK3gaciGTWPwHt0wlpNV15vwmswBAUSII= github.com/agnivade/levenshtein v1.0.1/go.mod h1:CURSv5d9Uaml+FovSIICkLbAUZ9S4RqaHDIsdSBg7lM= -github.com/agnivade/levenshtein v1.1.0/go.mod h1:veldBMzWxcCG2ZvUTKD2kJNRdCk5hVbJomOvKkmgYbo= github.com/agnivade/levenshtein v1.1.1 h1:QY8M92nrzkmr798gCo3kmMyqXFzdQVpxLlGPRBij0P8= github.com/agnivade/levenshtein v1.1.1/go.mod h1:veldBMzWxcCG2ZvUTKD2kJNRdCk5hVbJomOvKkmgYbo= github.com/alecthomas/template v0.0.0-20160405071501-a0175ee3bccc/go.mod h1:LOuyumcjzFXgccqObfd/Ljyb9UuFJ6TxHnclSeseNhc= @@ -173,7 +173,6 @@ github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/decred/dcrd/crypto/blake256 v1.0.0 h1:/8DMNYp9SGi5f0w7uCm6d6M4OU2rGFK09Y2A4Xv7EE0= github.com/decred/dcrd/crypto/blake256 v1.0.0/go.mod h1:sQl2p6Y26YV+ZOcSTP6thNdn47hh8kt6rqSlvmrXFAc= -github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1 h1:YLtO71vCjJRCBcrPMtQ9nqBsqpA1m5sE92cU+pd5Mcc= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1/go.mod h1:hyedUtir6IdtD/7lIxGeCxkaw7y45JueMRL4DIyJDKs= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.1.0 h1:HbphB4TFFXpv7MNrT52FGrrgVXF1owhMVTHFZIlnvd4= github.com/decred/dcrd/dcrec/secp256k1/v4 v4.1.0/go.mod h1:DZGJHZMqrU4JJqFAWUS2UO1+lbSKsdiOoYi9Zzey7Fc= @@ -310,8 +309,9 @@ github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+ github.com/googleapis/gax-go/v2 v2.0.4/go.mod h1:0Wqv26UfaUD9n4G6kQubkQ+KchISgw+vpHVxEJEs9eg= github.com/googleapis/gax-go/v2 v2.0.5/go.mod h1:DWXyrwAJ9X0FpwwEdw+IPEYBICEFu5mhpdKc/us6bOk= github.com/gopherjs/gopherjs v0.0.0-20181017120253-0766667cb4d1/go.mod h1:wJfORRmW1u3UXTncJ5qlYoELFm8eSnnEO6hX4iZ3EWY= -github.com/gorilla/websocket v1.4.2 h1:+/TMaTYc4QFitKJxsQ7Yye35DkWvkdLcvGKqM+x0Ufc= github.com/gorilla/websocket v1.4.2/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= +github.com/gorilla/websocket v1.5.0 h1:PPwGk2jz7EePpoHN/+ClbZu8SPxiqlu12wZP/3sWmnc= +github.com/gorilla/websocket v1.5.0/go.mod h1:YR8l580nyteQvAITg2hZ9XVh4b55+EU/adAjf1fMHhE= github.com/grpc-ecosystem/go-grpc-middleware v1.0.0/go.mod h1:FiyG127CGDf3tlThmgyCl78X/SZQqEOJBCDaAfeWzPs= github.com/grpc-ecosystem/go-grpc-middleware v1.3.0 h1:+9834+KizmvFV7pXQGSXQTsaWhq2GjuNUt0aUU0YBYw= github.com/grpc-ecosystem/go-grpc-middleware v1.3.0/go.mod h1:z0ButlSOZa5vEBq9m2m2hlwIgKw+rp3sdCBRoJY+30Y= @@ -528,19 +528,18 @@ github.com/masterzen/azure-sdk-for-go v3.2.0-beta.0.20161014135628-ee4f0065d00c+ github.com/masterzen/simplexml v0.0.0-20160608183007-4572e39b1ab9/go.mod h1:kCEbxUJlNDEBNbdQMkPSp6yaKcRXVI6f4ddk8Riv4bc= github.com/masterzen/winrm v0.0.0-20161014151040-7a535cd943fc/go.mod h1:CfZSN7zwz5gJiFhZJz49Uzk7mEBHIceWmbFmYx7Hf7E= github.com/masterzen/xmlpath v0.0.0-20140218185901-13f4951698ad/go.mod h1:A0zPC53iKKKcXYxr4ROjpQRQ5FgJXtelNdSmHHuq/tY= -github.com/matryer/moq v0.2.3 h1:Q06vEqnBYjjfx5KKgHfYRKE/lvlRu+Nj+xodG4YdHnU= -github.com/matryer/moq v0.2.3/go.mod h1:9RtPYjTnH1bSBIkpvtHkFN7nbWAnO7oRpdJkEIn6UtE= +github.com/matryer/moq v0.2.7/go.mod h1:kITsx543GOENm48TUAQyJ9+SAvFSr7iGQXPoth/VUBk= github.com/mattn/go-colorable v0.0.6/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= github.com/mattn/go-colorable v0.0.9/go.mod h1:9vuHe8Xs5qXnSaW/c/ABM9alt+Vo+STaOChaDxuIBZU= github.com/mattn/go-colorable v0.1.1/go.mod h1:FuOcm+DKB9mbwrcAfNl7/TZVBZ6rcnceauSikq3lYCQ= -github.com/mattn/go-colorable v0.1.4/go.mod h1:U0ppj6V5qS13XJ6of8GYAs25YV2eR4EVcfRqFIhoBtE= github.com/mattn/go-colorable v0.1.6/go.mod h1:u6P/XSegPjTcexA+o6vUJrdnUu04hMope9wVRipJSqc= +github.com/mattn/go-colorable v0.1.13/go.mod h1:7S9/ev0klgBDR4GtXTXX8a3vIGJpMovkB8vQcUbaXHg= github.com/mattn/go-isatty v0.0.0-20160806122752-66b8e73f3f5c/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4= github.com/mattn/go-isatty v0.0.3/go.mod h1:M+lRXTBqGeGNdLjl/ufCoiOlB5xdOkqRJdNxMWT7Zi4= github.com/mattn/go-isatty v0.0.5/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= github.com/mattn/go-isatty v0.0.7/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= -github.com/mattn/go-isatty v0.0.8/go.mod h1:Iq45c/XA43vh69/j3iqttzPXn0bhXyGjM0Hdxcsrc5s= github.com/mattn/go-isatty v0.0.12/go.mod h1:cbi8OIDigv2wuxKPP5vlRcQ1OAZbq2CE4Kysco4FUpU= +github.com/mattn/go-isatty v0.0.16/go.mod h1:kYGgaQfpe5nmfYZH+SKPsOc2e4SrIfOl2e/yFXSvRLM= github.com/mattn/go-runewidth v0.0.13/go.mod h1:Jdepj2loyihRzMpdS35Xk/zdY8IAYHsh153qUoGf23w= github.com/matttproud/golang_protobuf_extensions v1.0.1 h1:4hp9jkHxhMHkqkrB3Ix0jegS5sx/RkqARlsWZ6pIwiU= github.com/matttproud/golang_protobuf_extensions v1.0.1/go.mod h1:D8He9yQNgCq6Z5Ld7szi9bcBfOoFv/3dc6xSMkL2PC0= @@ -557,7 +556,7 @@ github.com/mitchellh/gox v0.4.0/go.mod h1:Sd9lOJ0+aimLBi73mGofS1ycjY8lL3uZM3JPS4 github.com/mitchellh/iochan v1.0.0/go.mod h1:JwYml1nuB7xOzsp52dPpHFffvOCDupsG0QubkSMEySY= github.com/mitchellh/mapstructure v0.0.0-20160808181253-ca63d7c062ee/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= github.com/mitchellh/mapstructure v1.1.2/go.mod h1:FVVH3fgwuzCH5S8UJGiWEs2h04kUh9fWfEaFds41c1Y= -github.com/mitchellh/mapstructure v1.2.3/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= +github.com/mitchellh/mapstructure v1.3.1/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/mitchellh/mapstructure v1.4.2 h1:6h7AQ0yhTcIsmFmnAwQls75jp2Gzs4iB8W7pjMO+rqo= github.com/mitchellh/mapstructure v1.4.2/go.mod h1:bFUtVrKA4DC2yAKiSyO/QUcy7e+RRV2QTWOzhPopBRo= github.com/modern-go/concurrent v0.0.0-20180228061459-e0a39a4cb421/go.mod h1:6dJC0mAP4ikYIbvyc7fijjWJddQyLn8Ig3JB5CqoB9Q= @@ -639,60 +638,16 @@ github.com/russross/blackfriday/v2 v2.0.1/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQD github.com/russross/blackfriday/v2 v2.1.0 h1:JIOH55/0cWyOuilr9/qlrm0BSXldqnqwMsf35Ld67mk= github.com/russross/blackfriday/v2 v2.1.0/go.mod h1:+Rmxgy9KzJVeS9/2gXHxylqXiyQDYRxCVz55jmeOWTM= github.com/ryanuber/columnize v0.0.0-20160712163229-9b3edd62028f/go.mod h1:sm1tb6uqfes/u+d4ooFouqFdy9/2g9QGwK3SQygK0Ts= -github.com/satimoto/go-datastore v0.2.1-0.20220908204239-b431699d8e29 h1:oaQqzAiWjk9C6JZkMazcYCH78e2LJEVf9Bpud6OzqKk= -github.com/satimoto/go-datastore v0.2.1-0.20220908204239-b431699d8e29/go.mod h1:SvM8losYPwH6hJgUKLkjNtQwVv06lZgCMWl8cGdllCM= -github.com/satimoto/go-datastore v0.2.1-0.20220909113251-cd5afc82f45d h1:/GKM9moe1Zu/IR0pYJezR1CGUbDycSa+kW/cdsKIXhQ= -github.com/satimoto/go-datastore v0.2.1-0.20220909113251-cd5afc82f45d/go.mod h1:SvM8losYPwH6hJgUKLkjNtQwVv06lZgCMWl8cGdllCM= -github.com/satimoto/go-datastore v0.3.1-0.20220913192348-54b6b204f971 h1:QK7WLvgQ92z+KKzU1A6WrC65vQYEwSDhXjz+Nv7X9GA= -github.com/satimoto/go-datastore v0.3.1-0.20220913192348-54b6b204f971/go.mod h1:SvM8losYPwH6hJgUKLkjNtQwVv06lZgCMWl8cGdllCM= -github.com/satimoto/go-datastore v0.3.1-0.20220914214546-40fc25a69ff7 h1:hnvf72sST7ZB3Vd5XkoJrbGzNltvk/WXLiuE1FklAAc= -github.com/satimoto/go-datastore v0.3.1-0.20220914214546-40fc25a69ff7/go.mod h1:SvM8losYPwH6hJgUKLkjNtQwVv06lZgCMWl8cGdllCM= -github.com/satimoto/go-datastore v0.3.1-0.20220915183717-06f735c0d779 h1:/OCOrMeEM9MzRE4m98W2nudo6VrqnwmTyCEUc2oWQeU= -github.com/satimoto/go-datastore v0.3.1-0.20220915183717-06f735c0d779/go.mod h1:SvM8losYPwH6hJgUKLkjNtQwVv06lZgCMWl8cGdllCM= -github.com/satimoto/go-datastore v0.3.1-0.20220918191156-6c48fa090ed4 h1:yAAqnZUKwURCtpQCWYJ0acRTZuVYyEss6PqQBB6mnGA= -github.com/satimoto/go-datastore v0.3.1-0.20220918191156-6c48fa090ed4/go.mod h1:SvM8losYPwH6hJgUKLkjNtQwVv06lZgCMWl8cGdllCM= -github.com/satimoto/go-datastore v0.3.1-0.20220919072639-319fde859fce h1:ZgxHPvIpBP3nm9jODWxfbzzBDp2LnRQ3XpuyQp2zyPc= -github.com/satimoto/go-datastore v0.3.1-0.20220919072639-319fde859fce/go.mod h1:SvM8losYPwH6hJgUKLkjNtQwVv06lZgCMWl8cGdllCM= -github.com/satimoto/go-datastore v0.3.1-0.20220919080036-d75c1f46898a h1:gWFiCeA4oQXXjeFo6RKosXzC9FA5NP5tVb/YJdQnMOI= -github.com/satimoto/go-datastore v0.3.1-0.20220919080036-d75c1f46898a/go.mod h1:SvM8losYPwH6hJgUKLkjNtQwVv06lZgCMWl8cGdllCM= -github.com/satimoto/go-datastore v0.3.1-0.20220919080523-675d9b6adb96 h1:Eu67rJB7TQdtA28xhFHn3StrGzihK9nNxFALAOrkhjE= -github.com/satimoto/go-datastore v0.3.1-0.20220919080523-675d9b6adb96/go.mod h1:SvM8losYPwH6hJgUKLkjNtQwVv06lZgCMWl8cGdllCM= -github.com/satimoto/go-datastore v0.3.1-0.20220921063225-0aa3a4131f00 h1:YkYKU1h5I7zM26ir87Inw496wD9DKFgW24UCJgavg/4= -github.com/satimoto/go-datastore v0.3.1-0.20220921063225-0aa3a4131f00/go.mod h1:SvM8losYPwH6hJgUKLkjNtQwVv06lZgCMWl8cGdllCM= -github.com/satimoto/go-datastore v0.3.1-0.20220921143057-7c676af4bf7c h1:1HPn3IvEH2tQUJavRkbuGnJeaWT2xIQnETjqwXhizUQ= -github.com/satimoto/go-datastore v0.3.1-0.20220921143057-7c676af4bf7c/go.mod h1:SvM8losYPwH6hJgUKLkjNtQwVv06lZgCMWl8cGdllCM= -github.com/satimoto/go-datastore v0.3.1-0.20220923103917-5ee40c184ca7 h1:CbCOu92CQr4NqpThDfdZQsweGlz3u57steYbMrNGN6E= -github.com/satimoto/go-datastore v0.3.1-0.20220923103917-5ee40c184ca7/go.mod h1:SvM8losYPwH6hJgUKLkjNtQwVv06lZgCMWl8cGdllCM= -github.com/satimoto/go-datastore v0.3.1-0.20220923113742-008a8f00d4eb h1:ImUuG5ZD9NPviyxNqMjXWIjzpqtiUSU91NmvTsURFD8= -github.com/satimoto/go-datastore v0.3.1-0.20220923113742-008a8f00d4eb/go.mod h1:SvM8losYPwH6hJgUKLkjNtQwVv06lZgCMWl8cGdllCM= -github.com/satimoto/go-datastore v0.3.1-0.20220924183147-e0edff9d9cc7 h1:Q3+CYSVaZx2y+mfKk6ojISa5ZjelcQLR5pDzvGWBef8= -github.com/satimoto/go-datastore v0.3.1-0.20220924183147-e0edff9d9cc7/go.mod h1:SvM8losYPwH6hJgUKLkjNtQwVv06lZgCMWl8cGdllCM= -github.com/satimoto/go-datastore v0.3.1-0.20220924195801-e58d30eb692b h1:Uhu+nGvURBozW9hczVu0G6zmnT3tPEI94N4Wggec8LA= -github.com/satimoto/go-datastore v0.3.1-0.20220924195801-e58d30eb692b/go.mod h1:SvM8losYPwH6hJgUKLkjNtQwVv06lZgCMWl8cGdllCM= -github.com/satimoto/go-datastore v0.3.1-0.20220925132216-fbe63357eab3 h1:vGsymg0drSShLh6ZElvzfAnTk1NQnCjNqS13w41geUo= -github.com/satimoto/go-datastore v0.3.1-0.20220925132216-fbe63357eab3/go.mod h1:SvM8losYPwH6hJgUKLkjNtQwVv06lZgCMWl8cGdllCM= -github.com/satimoto/go-datastore v0.3.1-0.20220925151125-2d2c9cc98c16 h1:IpBGZ/IvdJqV6PUUe2TkP3i8dTE6zSAmmWbG4JS/X/U= -github.com/satimoto/go-datastore v0.3.1-0.20220925151125-2d2c9cc98c16/go.mod h1:SvM8losYPwH6hJgUKLkjNtQwVv06lZgCMWl8cGdllCM= -github.com/satimoto/go-datastore v0.3.1-0.20220930070309-395f616e2a91 h1:e+LIjjaJ3D7c5/1CA79DO4hsGz8ehPT0fCkN1A6s0hY= -github.com/satimoto/go-datastore v0.3.1-0.20220930070309-395f616e2a91/go.mod h1:SvM8losYPwH6hJgUKLkjNtQwVv06lZgCMWl8cGdllCM= github.com/satimoto/go-datastore v0.3.1-0.20220930074556-db0579f24964 h1:1aLa8xIbL5YzND31angYkvdLoOm2RXNqKNhfajglvKA= github.com/satimoto/go-datastore v0.3.1-0.20220930074556-db0579f24964/go.mod h1:SvM8losYPwH6hJgUKLkjNtQwVv06lZgCMWl8cGdllCM= github.com/satimoto/go-ferp v0.1.1-0.20220908195810-ff288d2a2a2f h1:emb13r6KZW3+8sUySFsfdK63+r6MVyoF+uvX+9KzsLQ= github.com/satimoto/go-ferp v0.1.1-0.20220908195810-ff288d2a2a2f/go.mod h1:GQdhGMwlWYwyFMO/cLhl1dRrHbKhQxKeuiPs35amvV4= -github.com/satimoto/go-lsp v0.1.1-0.20220908195954-f81b0c6a2c31 h1:qm/yJ4sCgHdRcIxKwDDbu/LwYHbLw5eBbkKM2hPtC2E= -github.com/satimoto/go-lsp v0.1.1-0.20220908195954-f81b0c6a2c31/go.mod h1:X/AXpdjor29h7A1C9cVkJzfsJSuHX+NmmyVeFsiE8QI= -github.com/satimoto/go-lsp v0.1.1-0.20220909113519-7f771fea0fb2 h1:nYhsXoUWDQP6rj9CfZGvt8jMpdGr71RnVmkfTX4UX5w= -github.com/satimoto/go-lsp v0.1.1-0.20220909113519-7f771fea0fb2/go.mod h1:tit5pUnRQ+7QvuoBr0TwM+K7zvLYgF4SWJdPlLmWju4= -github.com/satimoto/go-lsp v0.1.1-0.20220910190547-fc41f26e7e1e h1:yhB6lYOZvHngZjXkETjy33PzUwIrCdC6IE1j9oL8p2A= -github.com/satimoto/go-lsp v0.1.1-0.20220910190547-fc41f26e7e1e/go.mod h1:tit5pUnRQ+7QvuoBr0TwM+K7zvLYgF4SWJdPlLmWju4= -github.com/satimoto/go-lsp v0.2.1-0.20220919145641-bfcc84abc2a9 h1:xpI+6MevQlqehdpXof4yhpUsPxAD99EHV61uSSOj+LI= -github.com/satimoto/go-lsp v0.2.1-0.20220919145641-bfcc84abc2a9/go.mod h1:cF6FKWk1GGEmjqAoWOnO29QPr93Nthrnxc0YhY9VjrI= github.com/satimoto/go-lsp v0.2.1-0.20220919200559-6ab40df2ed28 h1:2ut6UBRJoSRjJcGbfpoDRP5Y/8NMleQArCHCkhYtV2o= github.com/satimoto/go-lsp v0.2.1-0.20220919200559-6ab40df2ed28/go.mod h1:cF6FKWk1GGEmjqAoWOnO29QPr93Nthrnxc0YhY9VjrI= -github.com/satimoto/go-ocpi v0.0.3-0.20220718065459-d1352ae31bf1 h1:4RsDh1SvctTf9VoDuY63ZUdn3S+MwX7wjFiVN8lFlm0= -github.com/satimoto/go-ocpi v0.0.3-0.20220718065459-d1352ae31bf1/go.mod h1:sXxH0RJgoZK8kNCOPkm3sUri5diFfx7/468f5dluC9s= -github.com/satimoto/go-ocpi v0.2.1-0.20220923105144-3c3054ca1740 h1:daRzbcK1NwCxfJo8G4/JMP2FCzsy5AgSQH66aYeoCjg= -github.com/satimoto/go-ocpi v0.2.1-0.20220923105144-3c3054ca1740/go.mod h1:2Yq6kxpOT1AXZpnJyMH25PmgmfDKLu0e1rhPAoWg3xA= +github.com/satimoto/go-ocpi v0.2.1-0.20221004133703-59a86fbf5046 h1:3a17uViwYi6XAWbFwH3yOaFoq2N05jKdYxhC8xrm7iE= +github.com/satimoto/go-ocpi v0.2.1-0.20221004133703-59a86fbf5046/go.mod h1:XsGgildR0lZqcOaFN837W8UXFwRiM5LCmns8wWvT2+E= +github.com/satimoto/go-ocpi v0.2.1-0.20221004141626-e7ce17baeb36 h1:eMovc5q7sV8xmjakOY7DpathlYuxvCxi5Y2+Q9GuQa8= +github.com/satimoto/go-ocpi v0.2.1-0.20221004141626-e7ce17baeb36/go.mod h1:XsGgildR0lZqcOaFN837W8UXFwRiM5LCmns8wWvT2+E= github.com/satori/go.uuid v1.2.0/go.mod h1:dA0hQrYB0VpLJoorglMZABFdXlWrHn1NEOzdhQKdks0= github.com/sean-/seed v0.0.0-20170313163322-e2103e2c3529/go.mod h1:DxrIzT+xaE7yg65j358z/aeFdxmN0P9QXhEzd20vsDc= github.com/sergi/go-diff v1.1.0 h1:we8PVUC3FE2uYfodKH/nBHMSetSfHDR6scGdBi+erh0= @@ -752,20 +707,23 @@ github.com/ulikunitz/xz v0.5.7/go.mod h1:nbz6k7qbPmH4IRqmfOplQw/tblSgqTqBwxkY0oW github.com/ulikunitz/xz v0.5.10 h1:t92gobL9l3HE202wg3rlk19F6X+JOxl9BBrCCMYEYd8= github.com/ulikunitz/xz v0.5.10/go.mod h1:nbz6k7qbPmH4IRqmfOplQw/tblSgqTqBwxkY0oWt/14= github.com/urfave/cli v1.22.4/go.mod h1:Gos4lmkARVdJ6EkW0WaNv/tZAAMe9V7XWyB60NtXRu0= -github.com/urfave/cli/v2 v2.3.0 h1:qph92Y649prgesehzOrQjdWyxFOp/QVM+6imKHad91M= -github.com/urfave/cli/v2 v2.3.0/go.mod h1:LJmUH05zAU44vOAcrfzZQKsZbVcdbOG8rtL3/XcUArI= -github.com/vektah/gqlparser/v2 v2.4.0 h1:EmA4dw9mqHm0j6Xzb9T21hOrp3oXmxnS40vwki70DZU= -github.com/vektah/gqlparser/v2 v2.4.0/go.mod h1:flJWIR04IMQPGz+BXLrORkrARBxv/rtyIAFvd/MceW0= +github.com/urfave/cli/v2 v2.8.1 h1:CGuYNZF9IKZY/rfBe3lJpccSoIY1ytfvmgQT90cNOl4= +github.com/urfave/cli/v2 v2.8.1/go.mod h1:Z41J9TPoffeoqP0Iza0YbAhGvymRdZAd2uPmZ5JxRdY= +github.com/vektah/gqlparser/v2 v2.5.1 h1:ZGu+bquAY23jsxDRcYpWjttRZrUz07LbiY77gUOHcr4= +github.com/vektah/gqlparser/v2 v2.5.1/go.mod h1:mPgqFBu/woKTVYWyNk8cO3kh4S/f4aRFZrvOnp3hmCs= github.com/xi2/xz v0.0.0-20171230120015-48954b6210f8 h1:nIPpBwaJSVYIxUFsDv3M8ofmx9yWTog9BfvIu0q41lo= github.com/xi2/xz v0.0.0-20171230120015-48954b6210f8/go.mod h1:HUYIGzjTL3rfEspMxjDjgmT5uz5wzYJKVo23qUhYTos= github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2 h1:eY9dn8+vbi4tKz5Qo6v2eYzo7kUS51QINcR5jNpbZS8= github.com/xiang90/probing v0.0.0-20190116061207-43a291ad63a2/go.mod h1:UETIi67q53MR2AWcXfiuqkDkRtnGDLqkBTpCHuJHxtU= +github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673 h1:bAn7/zixMGCfxrRTfdpNzjtPYqr8smhKouy9mxVdGPU= +github.com/xrash/smetrics v0.0.0-20201216005158-039620a65673/go.mod h1:N3UwUGtsrSj3ccvlPHLoLsHnpR27oXr4ZE984MbSER8= github.com/yuin/goldmark v1.1.25/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.27/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.1.32/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.2.1/go.mod h1:3hX8gzYuyVAZsxl0MRgGTJEmQBFcNTphYh9decYSb74= github.com/yuin/goldmark v1.3.5/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= github.com/yuin/goldmark v1.4.1/go.mod h1:mwnBkeHKe2W/ZEtQ+71ViKU8L12m81fl3OWwC1Zlc8k= +github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= github.com/zenazn/goji v0.9.0/go.mod h1:7S9M489iMyHBNxwZnk9/EHS098H4/F6TATF2mIxtB1Q= gitlab.com/yawning/bsaes.git v0.0.0-20190805113838-0a714cd429ec/go.mod h1:BZ1RAoRPbCxum9Grlv5aeksu2H8BiKehBYooU2LFiOQ= go.etcd.io/bbolt v1.3.2/go.mod h1:IbVyRI1SCnLcuJnV2u8VeU0CEYM7e686BmAb1XKL+uU= @@ -884,8 +842,10 @@ golang.org/x/mod v0.2.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.3.0/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.4.2/go.mod h1:s0Qsj1ACt9ePp/hMypM3fl4fZqREWJwdYDEqhRiZZUA= golang.org/x/mod v0.5.1/go.mod h1:5OXOZSfqPIIbmVBIIKWRFfZjPR0E5r58TLhUjH0a2Ro= -golang.org/x/mod v0.6.0-dev.0.20211013180041-c96bc1413d57 h1:LQmS1nU0twXLA96Kt7U9qtHJEbBk3z6Q0V4UXjZkpr4= golang.org/x/mod v0.6.0-dev.0.20211013180041-c96bc1413d57/go.mod h1:3p9vT2HGsQu2K1YbXdKPJLVgG5VJdoTa1poYQBtP1AY= +golang.org/x/mod v0.6.0-dev.0.20220106191415-9b9b3d81d5e3/go.mod h1:3p9vT2HGsQu2K1YbXdKPJLVgG5VJdoTa1poYQBtP1AY= +golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4 h1:6zppjxzCulZykYSLyVDYbneBfbaBIQPYMevg0bEwv2s= +golang.org/x/mod v0.6.0-dev.0.20220419223038-86c51ed26bb4/go.mod h1:jJ57K6gSWd91VN4djpZkiMVwK6gcyfeH4XE8wZrZaV4= golang.org/x/net v0.0.0-20180406214816-61147c48b25b/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180719180050-a680a1efc54d/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= golang.org/x/net v0.0.0-20180724234803-3673e40ba225/go.mod h1:mL1N/T3taQHkDXs73rZJwtUhF3w3ftmwwsq0BUmARs4= @@ -932,8 +892,9 @@ golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v golang.org/x/net v0.0.0-20210405180319-a5a99cb37ef4/go.mod h1:p54w0d4576C0XHj96bSt6lcn1PtDYWL6XObtHCRCNQM= golang.org/x/net v0.0.0-20210525063256-abc453219eb5/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/net v0.0.0-20211015210444-4f30a5c0130f/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= -golang.org/x/net v0.0.0-20220127200216-cd36cc0744dd h1:O7DYs+zxREGLKzKoMQrtrEacpb0ZVXA5rIwylE2Xchk= golang.org/x/net v0.0.0-20220127200216-cd36cc0744dd/go.mod h1:CfG3xpIq0wQ8r1q4Su4UZFWDARRcnwPjda9FqA0JpMk= +golang.org/x/net v0.0.0-20220722155237-a158d28d115b h1:PxfKdU9lEEDYjdIzOtC4qFWgkU2rGHdKlKowJSMN9h0= +golang.org/x/net v0.0.0-20220722155237-a158d28d115b/go.mod h1:XRhObCWvk6IyKnWLug+ECip1KBveYUHfp+8e9klMJ9c= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= @@ -951,8 +912,9 @@ golang.org/x/sync v0.0.0-20200317015054-43a5402ce75a/go.mod h1:RxMgew5VJxzue5/jJ golang.org/x/sync v0.0.0-20200625203802-6e8e738ad208/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201020160332-67f06af15bc9/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sync v0.0.0-20201207232520-09787c993a3a/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= -golang.org/x/sync v0.0.0-20210220032951-036812b2e83c h1:5KslGYwFpkhGh+Q16bwMP3cOontH8FOep7tGV86Y7SQ= golang.org/x/sync v0.0.0-20210220032951-036812b2e83c/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= +golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4 h1:uVc8UZUe6tr40fFVnUP5Oj+veunVezqYl9z7DYw9xzw= +golang.org/x/sync v0.0.0-20220722155255-886fb9371eb4/go.mod h1:RxMgew5VJxzue5/jJTE5uejpjVlOe/izrB70Jof72aM= golang.org/x/sys v0.0.0-20180816055513-1c9583448a9c/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180823144017-11551d06cbcc/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= golang.org/x/sys v0.0.0-20180830151530-49385e6e1522/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY= @@ -1016,8 +978,10 @@ golang.org/x/sys v0.0.0-20210615035016-665e8c7367d1/go.mod h1:oPkhp1MJrh7nUepCBc golang.org/x/sys v0.0.0-20211019181941-9d821ace8654/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20211216021012-1d35b9e2eb4e/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/sys v0.0.0-20220114195835-da31bd327af9/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= -golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a h1:dGzPydgVsqGcTRVwiLJ1jVbufYwmzD3LfVPLKsKg+0k= golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220722155257-8c9f86f7a55f/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= +golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab h1:2QkjZIsXupsJbJIdSjjUOgWK3aEtzyuh2mPt3l/CkeU= +golang.org/x/sys v0.0.0-20220811171246-fbc7d0a398ab/go.mod h1:oPkhp1MJrh7nUepCBck5+mAzfO9JrbApNNgaTdGDITg= golang.org/x/term v0.0.0-20201117132131-f5c789dd3221/go.mod h1:Nr5EML6q2oocZ2LXRh80K7BxOlk5/8JxuGnuhpl+muw= golang.org/x/term v0.0.0-20201126162022-7de9c90e9dd1/go.mod h1:bj7SfCRtBDWHUb9snDiAeCFNEtKQo2Wmx5Cou7ajbmo= golang.org/x/term v0.0.0-20210927222741-03fcf44c2211 h1:JGgROgKl9N8DuW20oFS5gxc+lE67/N3FcwmBPMe7ArY= @@ -1088,7 +1052,6 @@ golang.org/x/tools v0.0.0-20200618134242-20370b0cb4b2/go.mod h1:EkVYQZoAsY45+roY golang.org/x/tools v0.0.0-20200619180055-7c47624df98f/go.mod h1:EkVYQZoAsY45+roYkvgYkIh4xh/qjgUK9TdY2XT94GE= golang.org/x/tools v0.0.0-20200729194436-6467de6f59a7/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= golang.org/x/tools v0.0.0-20200804011535-6c149bb5ef0d/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= -golang.org/x/tools v0.0.0-20200815165600-90abf76919f3/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= golang.org/x/tools v0.0.0-20200825202427-b303f430e36d/go.mod h1:njjCfa9FT2d7l9Bc6FUM5FLjQPp3cFF28FI3qnDFljA= golang.org/x/tools v0.0.0-20210106214847-113979e3529a/go.mod h1:emZCQorbCU4vsT4fOWvOPXz4eW1wZW4PmDk9uLelYpA= golang.org/x/tools v0.1.2/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= @@ -1096,8 +1059,9 @@ golang.org/x/tools v0.1.3/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.5/go.mod h1:o0xws9oXOQQZyjljx8fwUC0k7L1pTE6eaCbjGeHmOkk= golang.org/x/tools v0.1.8-0.20211029000441-d6a9af8af023/go.mod h1:nABZi5QlRsZVlzPpHl034qft6wpY4eDcsTt5AaioBiU= golang.org/x/tools v0.1.8/go.mod h1:nABZi5QlRsZVlzPpHl034qft6wpY4eDcsTt5AaioBiU= -golang.org/x/tools v0.1.9 h1:j9KsMiaP1c3B0OTQGth0/k+miLGTgLsAFUCrF2vLcF8= -golang.org/x/tools v0.1.9/go.mod h1:nABZi5QlRsZVlzPpHl034qft6wpY4eDcsTt5AaioBiU= +golang.org/x/tools v0.1.10/go.mod h1:Uh6Zz+xoGYZom868N8YTex3t7RhtHDBrE8Gzo9bV56E= +golang.org/x/tools v0.1.12 h1:VveCTK38A2rkS8ZqFY25HIDFscX5X9OoEhJd3quQmXU= +golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= golang.org/x/xerrors v0.0.0-20190410155217-1f06c39b4373/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20190513163551-3ee3066db522/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= @@ -1196,8 +1160,10 @@ google.golang.org/protobuf v1.24.0/go.mod h1:r/3tXBNzIEhYS9I1OUVjXDlt8tc493IdKGj google.golang.org/protobuf v1.25.0/go.mod h1:9JNX74DMeImyA3h4bdi1ymwjUzf21/xIlbajtzgsN7c= google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= google.golang.org/protobuf v1.26.0/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= -google.golang.org/protobuf v1.27.1 h1:SnqbnDw1V7RiZcXPx5MEeqPv2s79L9i7BJUlG/+RurQ= google.golang.org/protobuf v1.27.1/go.mod h1:9q0QmTI4eRPtz6boOQmLYwt+qCgq0jsYwAQnmE0givc= +google.golang.org/protobuf v1.28.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= +google.golang.org/protobuf v1.28.1 h1:d0NfwRgPtno5B1Wa6L2DAG+KivqkdutMf1UhdNx175w= +google.golang.org/protobuf v1.28.1/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= gopkg.in/alecthomas/kingpin.v2 v2.2.6/go.mod h1:FMv+mEhP44yOT+4EoQTLFTRgOQ1FBLkstjWtayDeSgw= gopkg.in/check.v1 v0.0.0-20161208181325-20d25e280405/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= gopkg.in/check.v1 v1.0.0-20160105164936-4f90aeace3a2/go.mod h1:Co6ibVJAznAaIkqp8huTwlJQCZ016jof/cbN4VW5Yz0= @@ -1233,8 +1199,9 @@ gopkg.in/yaml.v2 v2.3.0/go.mod h1:hI93XBmqTisBFMUTm0b8Fm+jr3Dg1NNxqwp+5A1VGuI= gopkg.in/yaml.v2 v2.4.0 h1:D8xgwECY7CYvx+Y2n4sBz93Jn9JRvxdiyyo8CTfuKaY= gopkg.in/yaml.v2 v2.4.0/go.mod h1:RDklbk79AGWmwhnvt/jBztapEOGDOx6ZbXqjP6csGnQ= gopkg.in/yaml.v3 v3.0.0-20200313102051-9f266ea9e77c/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= -gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b h1:h8qDotaEPuJATrMmW04NCwg7v22aHH28wwpauUhK9Oo= gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= +gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= +gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= honnef.co/go/tools v0.0.0-20180728063816-88497007e858/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190102054323-c2f93a96b099/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= honnef.co/go/tools v0.0.0-20190106161140-3f1c8253044a/go.mod h1:rf3lG4BRIbNafJWhAfAdb/ePZxsR/4RtNHQocxwk9r4= diff --git a/graph/exec.go b/graph/exec.go index a15a0fd..17c528b 100644 --- a/graph/exec.go +++ b/graph/exec.go @@ -5,7 +5,9 @@ package graph import ( "bytes" "context" + "embed" "errors" + "fmt" "strconv" "sync" "sync/atomic" @@ -272,6 +274,7 @@ type ComplexityRoot struct { RegisterCredential func(childComplexity int, input RegisterCredentialInput) int StartSession func(childComplexity int, input StartSessionInput) int StopSession func(childComplexity int, input StopSessionInput) int + SyncCredential func(childComplexity int, input SyncCredentialInput) int UnregisterCredential func(childComplexity int, input UnregisterCredentialInput) int UpdateInvoiceRequest func(childComplexity int, input UpdateInvoiceRequestInput) int UpdateUser func(childComplexity int, input UpdateUserInput) int @@ -329,7 +332,7 @@ type ComplexityRoot struct { Weekday func(childComplexity int) int } - ResultID struct { + ResultId struct { ID func(childComplexity int) int } @@ -540,6 +543,7 @@ type MutationResolver interface { StopSession(ctx context.Context, input StopSessionInput) (*StopSession, error) CreateCredential(ctx context.Context, input CreateCredentialInput) (*db.Credential, error) RegisterCredential(ctx context.Context, input RegisterCredentialInput) (*ResultID, error) + SyncCredential(ctx context.Context, input SyncCredentialInput) (*ResultID, error) UnregisterCredential(ctx context.Context, input UnregisterCredentialInput) (*ResultID, error) CreateEmailSubscription(ctx context.Context, input CreateEmailSubscriptionInput) (*db.EmailSubscription, error) VerifyEmailSubscription(ctx context.Context, input VerifyEmailSubscriptionInput) (*db.EmailSubscription, error) @@ -1707,6 +1711,18 @@ func (e *executableSchema) Complexity(typeName, field string, childComplexity in return e.complexity.Mutation.StopSession(childComplexity, args["input"].(StopSessionInput)), true + case "Mutation.syncCredential": + if e.complexity.Mutation.SyncCredential == nil { + break + } + + args, err := ec.field_Mutation_syncCredential_args(context.TODO(), rawArgs) + if err != nil { + return 0, false + } + + return e.complexity.Mutation.SyncCredential(childComplexity, args["input"].(SyncCredentialInput)), true + case "Mutation.unregisterCredential": if e.complexity.Mutation.UnregisterCredential == nil { break @@ -2001,11 +2017,11 @@ func (e *executableSchema) Complexity(typeName, field string, childComplexity in return e.complexity.RegularHour.Weekday(childComplexity), true case "ResultId.id": - if e.complexity.ResultID.ID == nil { + if e.complexity.ResultId.ID == nil { break } - return e.complexity.ResultID.ID(childComplexity), true + return e.complexity.ResultId.ID(childComplexity), true case "ResultOk.ok": if e.complexity.ResultOk.Ok == nil { @@ -2448,6 +2464,28 @@ func (e *executableSchema) Complexity(typeName, field string, childComplexity in func (e *executableSchema) Exec(ctx context.Context) graphql.ResponseHandler { rc := graphql.GetOperationContext(ctx) ec := executionContext{rc, e} + inputUnmarshalMap := graphql.BuildUnmarshalerMap( + ec.unmarshalInputCreateBusinessDetailInput, + ec.unmarshalInputCreateChannelRequestInput, + ec.unmarshalInputCreateCredentialInput, + ec.unmarshalInputCreateEmailSubscriptionInput, + ec.unmarshalInputCreateImageInput, + ec.unmarshalInputCreateReferralInput, + ec.unmarshalInputCreateUserInput, + ec.unmarshalInputGetLocationInput, + ec.unmarshalInputGetSessionInput, + ec.unmarshalInputGetTariffInput, + ec.unmarshalInputListLocationsInput, + ec.unmarshalInputPublishLocationInput, + ec.unmarshalInputRegisterCredentialInput, + ec.unmarshalInputStartSessionInput, + ec.unmarshalInputStopSessionInput, + ec.unmarshalInputSyncCredentialInput, + ec.unmarshalInputUnregisterCredentialInput, + ec.unmarshalInputUpdateInvoiceRequestInput, + ec.unmarshalInputUpdateUserInput, + ec.unmarshalInputVerifyEmailSubscriptionInput, + ) first := true switch rc.Operation.Operation { @@ -2457,6 +2495,7 @@ func (e *executableSchema) Exec(ctx context.Context) graphql.ResponseHandler { return nil } first = false + ctx = graphql.WithUnmarshalerMap(ctx, inputUnmarshalMap) data := ec._Query(ctx, rc.Operation.SelectionSet) var buf bytes.Buffer data.MarshalGQL(&buf) @@ -2471,6 +2510,7 @@ func (e *executableSchema) Exec(ctx context.Context) graphql.ResponseHandler { return nil } first = false + ctx = graphql.WithUnmarshalerMap(ctx, inputUnmarshalMap) data := ec._Mutation(ctx, rc.Operation.SelectionSet) var buf bytes.Buffer data.MarshalGQL(&buf) @@ -2504,533 +2544,52 @@ func (ec *executionContext) introspectType(name string) (*introspection.Type, er return introspection.WrapTypeFromDef(parsedSchema, parsedSchema.Types[name]), nil } -var sources = []*ast.Source{ - {Name: "graph/schema/additionalgeolocation.graphqls", Input: `type AddtionalGeoLocation { - latitude: Float! - longitude: Float! - name: DisplayText -}`, BuiltIn: false}, - {Name: "graph/schema/authentication.graphqls", Input: `enum AuthenticationAction { - register - login - link - auth +//go:embed "schema/additionalgeolocation.graphqls" "schema/authentication.graphqls" "schema/businessdetail.graphqls" "schema/channelrequest.graphqls" "schema/command.graphqls" "schema/connector.graphqls" "schema/credential.graphqls" "schema/displaytext.graphqls" "schema/elementrestriction.graphqls" "schema/emailsubscription.graphqls" "schema/energymix.graphqls" "schema/energysource.graphqls" "schema/environmentalimpact.graphqls" "schema/evse.graphqls" "schema/exceptionalperiod.graphqls" "schema/geolocation.graphqls" "schema/image.graphqls" "schema/invoicerequest.graphqls" "schema/location.graphqls" "schema/node.graphqls" "schema/openingtime.graphqls" "schema/pricecomponent.graphqls" "schema/promotion.graphqls" "schema/rate.graphqls" "schema/referral.graphqls" "schema/regularhour.graphqls" "schema/result.graphqls" "schema/session.graphqls" "schema/sessioninvoice.graphqls" "schema/statusschedule.graphqls" "schema/tariff.graphqls" "schema/tariffelement.graphqls" "schema/textdescription.graphqls" "schema/user.graphqls" +var sourcesFS embed.FS + +func sourceData(filename string) string { + data, err := sourcesFS.ReadFile(filename) + if err != nil { + panic(fmt.Sprintf("codegen problem: %s not available", filename)) + } + return string(data) } -type CreateAuthentication { - code: String! - lnUrl: String! -} - -type ExchangeAuthentication { - token: String! -} - -type VerifyAuthentication { - verified: Boolean! -} - -extend type Query { - verifyAuthentication(code: String!): VerifyAuthentication! -} - -extend type Mutation { - createAuthentication(action: AuthenticationAction!): CreateAuthentication! - exchangeAuthentication(code: String!): ExchangeAuthentication! -} -`, BuiltIn: false}, - {Name: "graph/schema/businessdetail.graphqls", Input: `type BusinessDetail { - name: String! - website: String - logo: Image -} - -input CreateBusinessDetailInput { - name: String! - website: String - logo: CreateImageInput -} -`, BuiltIn: false}, - {Name: "graph/schema/channelrequest.graphqls", Input: `type ChannelRequest { - id: ID! - """ - This field is base64 encoded. - """ - paymentHash: String! - """ - This field is base64 encoded. - """ - paymentAddr: String! - amountMsat: String! - node: Node! - pendingChanId: String! - scid: String! - feeBaseMsat: Int! - feeProportionalMillionths: Int! - cltvExpiryDelta: Int! -} - -input CreateChannelRequestInput { - """ - This field must be encoded as base64. - """ - paymentHash: String! - """ - This field must be encoded as base64. - """ - paymentAddr: String! - amountMsat: String! -} - -extend type Mutation { - createChannelRequest(input: CreateChannelRequestInput!): ChannelRequest! -} -`, BuiltIn: false}, - {Name: "graph/schema/command.graphqls", Input: `type StartSession { - id: ID! - status: String! - authorizationId: String! - verificationKey: String! - locationUid: String! - evseUid: String -} - -input StartSessionInput { - locationUid: String! - evseUid: String -} - -type StopSession { - id: ID! - status: String! - sessionUid: String! -} - -input StopSessionInput { - sessionUid: String! -} - -extend type Mutation { - startSession(input: StartSessionInput!): StartSession! - stopSession(input: StopSessionInput!): StopSession! -} -`, BuiltIn: false}, - {Name: "graph/schema/connector.graphqls", Input: `type Connector { - id: ID! - uid: String! - identifier: String - standard: String! - format: String! - powerType: String! - voltage: Int! - amperage: Int! - wattage: Int! - tariffId: String - tariff: Tariff - termsAndConditions: String - lastUpdated: String! -}`, BuiltIn: false}, - {Name: "graph/schema/credential.graphqls", Input: `type Credential { - id: ID! - url: String! - countryCode: String! - partyId: String! - isHub: Boolean! -} - -input CreateCredentialInput { - clientToken: String - url: String! - businessDetail: CreateBusinessDetailInput! - countryCode: String! - partyId: String! - isHub: Boolean! -} - -input RegisterCredentialInput { - id: ID! - clientToken: String -} - -input UnregisterCredentialInput { - id: ID! -} - -extend type Mutation { - createCredential(input: CreateCredentialInput!): Credential! - registerCredential(input: RegisterCredentialInput!): ResultId! - unregisterCredential(input: UnregisterCredentialInput!): ResultId! -} -`, BuiltIn: false}, - {Name: "graph/schema/displaytext.graphqls", Input: `type DisplayText { - language: String! - text: String! -} -`, BuiltIn: false}, - {Name: "graph/schema/elementrestriction.graphqls", Input: `type ElementRestriction { - startTime: String - endTime: String - startDate: String - endDate: String - minKwh: Float - maxKwh: Float - minPower: Float - maxPower: Float - minDuration: Int - maxDuration: Int - dayOfWeek: [String!] -}`, BuiltIn: false}, - {Name: "graph/schema/emailsubscription.graphqls", Input: `type EmailSubscription { - id: ID! - email: String! - locale: String! - isVerified: Boolean! -} - -input CreateEmailSubscriptionInput { - email: String! - locale: String -} - -input VerifyEmailSubscriptionInput { - email: String! - verificationCode: String! -} - -extend type Mutation { - createEmailSubscription(input: CreateEmailSubscriptionInput!): EmailSubscription! - verifyEmailSubscription(input: VerifyEmailSubscriptionInput!): EmailSubscription! -} -`, BuiltIn: false}, - {Name: "graph/schema/energymix.graphqls", Input: `type EnergyMix { - isGreenEnergy: Boolean! - energySources: [EnergySource!]! - environmentalImpact: [EnvironmentalImpact!]! - supplierName: String - energyProductName: String -}`, BuiltIn: false}, - {Name: "graph/schema/energysource.graphqls", Input: `type EnergySource { - source: String! - percentage: Float! -} -`, BuiltIn: false}, - {Name: "graph/schema/environmentalimpact.graphqls", Input: `type EnvironmentalImpact { - source: String! - amount: Float! -} -`, BuiltIn: false}, - {Name: "graph/schema/evse.graphqls", Input: `type Evse { - id: ID! - uid: String! - identifier: String - status: String! - statusSchedule: [StatusSchedule!]! - capabilities: [TextDescription!]! - connectors: [Connector!]! - floorLevel: String - geom: Geometry - isRemoteCapable: Boolean! - isRfidCapable: Boolean! - physicalReference: String - directions: [DisplayText!]! - parkingRestrictions: [TextDescription!]! - images: [Image!]! - lastUpdated: String! -}`, BuiltIn: false}, - {Name: "graph/schema/exceptionalperiod.graphqls", Input: `type ExceptionalPeriod { - periodBegin: String! - periodEnd: String! -} -`, BuiltIn: false}, - {Name: "graph/schema/geolocation.graphqls", Input: `type Geolocation { - latitude: Float! - longitude: Float! - name: String -} -`, BuiltIn: false}, - {Name: "graph/schema/image.graphqls", Input: `type Image { - url: String! - thumbnail: String - category: String! - type: String! - width: Int - height: Int -} - -input CreateImageInput { - url: String! - thumbnail: String - category: String! - type: String! - width: Int - height: Int -} -`, BuiltIn: false}, - {Name: "graph/schema/invoicerequest.graphqls", Input: `type InvoiceRequest { - id: ID! - promotion: Promotion! - currency: String! - memo: String! - priceFiat: Float - priceMsat: Int - commissionFiat: Float - commissionMsat: Int - taxFiat: Float - taxMsat: Int - totalFiat: Float! - totalMsat: Int! -} - -input UpdateInvoiceRequestInput { - id: ID! - paymentRequest: String! -} - -extend type Query { - listInvoiceRequests: [InvoiceRequest!]! -} - -extend type Mutation { - updateInvoiceRequest(input: UpdateInvoiceRequestInput!): InvoiceRequest! -}`, BuiltIn: false}, - {Name: "graph/schema/location.graphqls", Input: `type ListLocation { - uid: String! - name: String! - geom: Geometry! - availableEvses: Int! - totalEvses: Int! - isRemoteCapable: Boolean! - isRfidCapable: Boolean! -} - -type Location { - id: ID! - uid: String! - type: String! - name: String - address: String! - city: String! - postalCode: String! - country: String! - geom: Geometry! - relatedLocations: [AddtionalGeoLocation!]! - evses: [Evse!]! - availableEvses: Int! - totalEvses: Int! - isRemoteCapable: Boolean! - isRfidCapable: Boolean! - directions: [DisplayText!]! - operator: BusinessDetail - suboperator: BusinessDetail - owner: BusinessDetail - facilities: [TextDescription!]! - timeZone: String - openingTime: OpeningTime - chargingWhenClosed: Boolean! - images: [Image!]! - energyMix: EnergyMix - lastUpdated: String! -} - -input GetLocationInput { - id: ID - uid: String -} - -input ListLocationsInput { - xMin: Float! - yMin: Float! - xMax: Float! - yMax: Float! - interval: Int -} - -input PublishLocationInput { - id: ID - credentialId: ID - countryCode: String - partyId: String - publish: Boolean! -} - -extend type Query { - getLocation(input: GetLocationInput!): Location! - listLocations(input: ListLocationsInput!): [ListLocation!]! -} - -extend type Mutation { - publishLocation(input: PublishLocationInput!): ResultOk! -} - -scalar Geometry`, BuiltIn: false}, - {Name: "graph/schema/node.graphqls", Input: `type Node { - pubkey: String! - addr: String! - alias: String! -} -`, BuiltIn: false}, - {Name: "graph/schema/openingtime.graphqls", Input: `type OpeningTime { - regularHours: [RegularHour!]! - twentyfourseven: Boolean! - exceptionalOpenings: [ExceptionalPeriod!]! - exceptionalClosings: [ExceptionalPeriod!]! -} -`, BuiltIn: false}, - {Name: "graph/schema/pricecomponent.graphqls", Input: `type PriceComponent { - type: String! - price: Float! - priceMsat: Int! - commissionMsat: Int! - taxMsat: Int - stepSize: Int! -}`, BuiltIn: false}, - {Name: "graph/schema/promotion.graphqls", Input: `type Promotion { - code: String! - description: String! -} -`, BuiltIn: false}, - {Name: "graph/schema/rate.graphqls", Input: `type Rate { - rate: String! - rateMsat: String! - lastUpdated: String! -} - -extend type Query { - getRate(currency: String!): Rate -} -`, BuiltIn: false}, - {Name: "graph/schema/referral.graphqls", Input: `input CreateReferralInput { - code: String! - referrer: String! -} - -extend type Mutation { - createReferral(input: CreateReferralInput!): ResultId! -} -`, BuiltIn: false}, - {Name: "graph/schema/regularhour.graphqls", Input: `type RegularHour { - weekday: Int! - periodBegin: String! - periodEnd: String! -} -`, BuiltIn: false}, - {Name: "graph/schema/result.graphqls", Input: `type ResultId { - id: ID! -} - -type ResultOk { - ok: Boolean! -}`, BuiltIn: false}, - {Name: "graph/schema/session.graphqls", Input: `type Session { - id: ID! - uid: String! - authorizationId: String - startDatetime: String! - endDatetime: String - kwh: Float! - authMethod: String! - location: Location! - evse: Evse! - connector: Connector! - meterId: String - sessionInvoices: [SessionInvoice!]! - status: String! - lastUpdated: String! -} - -input GetSessionInput { - id: ID - uid: String - authorizationId: String -} - -extend type Query { - getSession(input: GetSessionInput!): Session! -}`, BuiltIn: false}, - {Name: "graph/schema/sessioninvoice.graphqls", Input: `type SessionInvoice { - id: ID! - currency: String! - currencyRate: Int! - currencyRateMsat: Int! - priceFiat: Float! - priceMsat: Int! - commissionFiat: Float! - commissionMsat: Int! - taxFiat: Float! - taxMsat: Int! - totalFiat: Float! - totalMsat: Int! - paymentRequest: String! - signature: String! - isSettled: Boolean! - isExpired: Boolean! - lastUpdated: String! -} - -extend type Query { - getSessionInvoice(id: ID!): SessionInvoice -}`, BuiltIn: false}, - {Name: "graph/schema/statusschedule.graphqls", Input: `type StatusSchedule { - periodBegin: String! - periodEnd: String - status: String! -}`, BuiltIn: false}, - {Name: "graph/schema/tariff.graphqls", Input: `type Tariff { - id: ID! - uid: String! - currency: String! - currencyRate: Int! - currencyRateMsat: Int! - commissionPercent: Float! - taxPercent: Float - elements: [TariffElement!]! - energyMix: EnergyMix -} - -input GetTariffInput { - id: ID - uid: String - country: String -} - -extend type Query { - getTariff(input: GetTariffInput!): Tariff! -}`, BuiltIn: false}, - {Name: "graph/schema/tariffelement.graphqls", Input: `type TariffElement { - priceComponents: [PriceComponent!] - restrictions: ElementRestriction -} -`, BuiltIn: false}, - {Name: "graph/schema/textdescription.graphqls", Input: `type TextDescription { - text: String! - description: String! -}`, BuiltIn: false}, - {Name: "graph/schema/user.graphqls", Input: `type User { - id: ID! - pubkey: String! - deviceToken: String! - referralCode: String -} - -input CreateUserInput { - code: String! - pubkey: String! - deviceToken: String! -} - -input UpdateUserInput { - deviceToken: String! -} - -extend type Query { - getUser: User! -} - -extend type Mutation { - createUser(input: CreateUserInput!): User! - updateUser(input: UpdateUserInput!): User! -} -`, BuiltIn: false}, +var sources = []*ast.Source{ + {Name: "schema/additionalgeolocation.graphqls", Input: sourceData("schema/additionalgeolocation.graphqls"), BuiltIn: false}, + {Name: "schema/authentication.graphqls", Input: sourceData("schema/authentication.graphqls"), BuiltIn: false}, + {Name: "schema/businessdetail.graphqls", Input: sourceData("schema/businessdetail.graphqls"), BuiltIn: false}, + {Name: "schema/channelrequest.graphqls", Input: sourceData("schema/channelrequest.graphqls"), BuiltIn: false}, + {Name: "schema/command.graphqls", Input: sourceData("schema/command.graphqls"), BuiltIn: false}, + {Name: "schema/connector.graphqls", Input: sourceData("schema/connector.graphqls"), BuiltIn: false}, + {Name: "schema/credential.graphqls", Input: sourceData("schema/credential.graphqls"), BuiltIn: false}, + {Name: "schema/displaytext.graphqls", Input: sourceData("schema/displaytext.graphqls"), BuiltIn: false}, + {Name: "schema/elementrestriction.graphqls", Input: sourceData("schema/elementrestriction.graphqls"), BuiltIn: false}, + {Name: "schema/emailsubscription.graphqls", Input: sourceData("schema/emailsubscription.graphqls"), BuiltIn: false}, + {Name: "schema/energymix.graphqls", Input: sourceData("schema/energymix.graphqls"), BuiltIn: false}, + {Name: "schema/energysource.graphqls", Input: sourceData("schema/energysource.graphqls"), BuiltIn: false}, + {Name: "schema/environmentalimpact.graphqls", Input: sourceData("schema/environmentalimpact.graphqls"), BuiltIn: false}, + {Name: "schema/evse.graphqls", Input: sourceData("schema/evse.graphqls"), BuiltIn: false}, + {Name: "schema/exceptionalperiod.graphqls", Input: sourceData("schema/exceptionalperiod.graphqls"), BuiltIn: false}, + {Name: "schema/geolocation.graphqls", Input: sourceData("schema/geolocation.graphqls"), BuiltIn: false}, + {Name: "schema/image.graphqls", Input: sourceData("schema/image.graphqls"), BuiltIn: false}, + {Name: "schema/invoicerequest.graphqls", Input: sourceData("schema/invoicerequest.graphqls"), BuiltIn: false}, + {Name: "schema/location.graphqls", Input: sourceData("schema/location.graphqls"), BuiltIn: false}, + {Name: "schema/node.graphqls", Input: sourceData("schema/node.graphqls"), BuiltIn: false}, + {Name: "schema/openingtime.graphqls", Input: sourceData("schema/openingtime.graphqls"), BuiltIn: false}, + {Name: "schema/pricecomponent.graphqls", Input: sourceData("schema/pricecomponent.graphqls"), BuiltIn: false}, + {Name: "schema/promotion.graphqls", Input: sourceData("schema/promotion.graphqls"), BuiltIn: false}, + {Name: "schema/rate.graphqls", Input: sourceData("schema/rate.graphqls"), BuiltIn: false}, + {Name: "schema/referral.graphqls", Input: sourceData("schema/referral.graphqls"), BuiltIn: false}, + {Name: "schema/regularhour.graphqls", Input: sourceData("schema/regularhour.graphqls"), BuiltIn: false}, + {Name: "schema/result.graphqls", Input: sourceData("schema/result.graphqls"), BuiltIn: false}, + {Name: "schema/session.graphqls", Input: sourceData("schema/session.graphqls"), BuiltIn: false}, + {Name: "schema/sessioninvoice.graphqls", Input: sourceData("schema/sessioninvoice.graphqls"), BuiltIn: false}, + {Name: "schema/statusschedule.graphqls", Input: sourceData("schema/statusschedule.graphqls"), BuiltIn: false}, + {Name: "schema/tariff.graphqls", Input: sourceData("schema/tariff.graphqls"), BuiltIn: false}, + {Name: "schema/tariffelement.graphqls", Input: sourceData("schema/tariffelement.graphqls"), BuiltIn: false}, + {Name: "schema/textdescription.graphqls", Input: sourceData("schema/textdescription.graphqls"), BuiltIn: false}, + {Name: "schema/user.graphqls", Input: sourceData("schema/user.graphqls"), BuiltIn: false}, } var parsedSchema = gqlparser.MustLoadSchema(sources...) @@ -3203,6 +2762,21 @@ func (ec *executionContext) field_Mutation_stopSession_args(ctx context.Context, return args, nil } +func (ec *executionContext) field_Mutation_syncCredential_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { + var err error + args := map[string]interface{}{} + var arg0 SyncCredentialInput + if tmp, ok := rawArgs["input"]; ok { + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("input")) + arg0, err = ec.unmarshalNSyncCredentialInput2githubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐSyncCredentialInput(ctx, tmp) + if err != nil { + return nil, err + } + } + args["input"] = arg0 + return args, nil +} + func (ec *executionContext) field_Mutation_unregisterCredential_args(ctx context.Context, rawArgs map[string]interface{}) (map[string]interface{}, error) { var err error args := map[string]interface{}{} @@ -3422,21 +2996,17 @@ func (ec *executionContext) field___Type_fields_args(ctx context.Context, rawArg // region **************************** field.gotpl ***************************** func (ec *executionContext) _AddtionalGeoLocation_latitude(ctx context.Context, field graphql.CollectedField, obj *AddtionalGeoLocation) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_AddtionalGeoLocation_latitude(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "AddtionalGeoLocation", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Latitude, nil @@ -3456,22 +3026,31 @@ func (ec *executionContext) _AddtionalGeoLocation_latitude(ctx context.Context, return ec.marshalNFloat2float64(ctx, field.Selections, res) } -func (ec *executionContext) _AddtionalGeoLocation_longitude(ctx context.Context, field graphql.CollectedField, obj *AddtionalGeoLocation) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_AddtionalGeoLocation_latitude(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "AddtionalGeoLocation", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _AddtionalGeoLocation_longitude(ctx context.Context, field graphql.CollectedField, obj *AddtionalGeoLocation) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_AddtionalGeoLocation_longitude(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Longitude, nil @@ -3491,22 +3070,31 @@ func (ec *executionContext) _AddtionalGeoLocation_longitude(ctx context.Context, return ec.marshalNFloat2float64(ctx, field.Selections, res) } -func (ec *executionContext) _AddtionalGeoLocation_name(ctx context.Context, field graphql.CollectedField, obj *AddtionalGeoLocation) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_AddtionalGeoLocation_longitude(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "AddtionalGeoLocation", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _AddtionalGeoLocation_name(ctx context.Context, field graphql.CollectedField, obj *AddtionalGeoLocation) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_AddtionalGeoLocation_name(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Name, nil @@ -3523,22 +3111,37 @@ func (ec *executionContext) _AddtionalGeoLocation_name(ctx context.Context, fiel return ec.marshalODisplayText2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐDisplayText(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_AddtionalGeoLocation_name(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "AddtionalGeoLocation", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "language": + return ec.fieldContext_DisplayText_language(ctx, field) + case "text": + return ec.fieldContext_DisplayText_text(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type DisplayText", field.Name) + }, + } + return fc, nil +} + func (ec *executionContext) _BusinessDetail_name(ctx context.Context, field graphql.CollectedField, obj *db.BusinessDetail) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_BusinessDetail_name(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "BusinessDetail", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Name, nil @@ -3558,22 +3161,31 @@ func (ec *executionContext) _BusinessDetail_name(ctx context.Context, field grap return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_BusinessDetail_name(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "BusinessDetail", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _BusinessDetail_website(ctx context.Context, field graphql.CollectedField, obj *db.BusinessDetail) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_BusinessDetail_website(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "BusinessDetail", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.BusinessDetail().Website(rctx, obj) @@ -3590,22 +3202,31 @@ func (ec *executionContext) _BusinessDetail_website(ctx context.Context, field g return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } -func (ec *executionContext) _BusinessDetail_logo(ctx context.Context, field graphql.CollectedField, obj *db.BusinessDetail) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_BusinessDetail_website(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "BusinessDetail", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _BusinessDetail_logo(ctx context.Context, field graphql.CollectedField, obj *db.BusinessDetail) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_BusinessDetail_logo(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.BusinessDetail().Logo(rctx, obj) @@ -3622,22 +3243,45 @@ func (ec *executionContext) _BusinessDetail_logo(ctx context.Context, field grap return ec.marshalOImage2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐImage(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_BusinessDetail_logo(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "BusinessDetail", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "url": + return ec.fieldContext_Image_url(ctx, field) + case "thumbnail": + return ec.fieldContext_Image_thumbnail(ctx, field) + case "category": + return ec.fieldContext_Image_category(ctx, field) + case "type": + return ec.fieldContext_Image_type(ctx, field) + case "width": + return ec.fieldContext_Image_width(ctx, field) + case "height": + return ec.fieldContext_Image_height(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Image", field.Name) + }, + } + return fc, nil +} + func (ec *executionContext) _ChannelRequest_id(ctx context.Context, field graphql.CollectedField, obj *db.ChannelRequest) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ChannelRequest_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "ChannelRequest", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.ID, nil @@ -3657,22 +3301,31 @@ func (ec *executionContext) _ChannelRequest_id(ctx context.Context, field graphq return ec.marshalNID2int64(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_ChannelRequest_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ChannelRequest", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _ChannelRequest_paymentHash(ctx context.Context, field graphql.CollectedField, obj *db.ChannelRequest) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ChannelRequest_paymentHash(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "ChannelRequest", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.ChannelRequest().PaymentHash(rctx, obj) @@ -3692,22 +3345,31 @@ func (ec *executionContext) _ChannelRequest_paymentHash(ctx context.Context, fie return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _ChannelRequest_paymentAddr(ctx context.Context, field graphql.CollectedField, obj *db.ChannelRequest) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ChannelRequest_paymentHash(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ChannelRequest", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ChannelRequest_paymentAddr(ctx context.Context, field graphql.CollectedField, obj *db.ChannelRequest) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ChannelRequest_paymentAddr(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.ChannelRequest().PaymentAddr(rctx, obj) @@ -3727,22 +3389,31 @@ func (ec *executionContext) _ChannelRequest_paymentAddr(ctx context.Context, fie return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _ChannelRequest_amountMsat(ctx context.Context, field graphql.CollectedField, obj *db.ChannelRequest) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ChannelRequest_paymentAddr(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ChannelRequest", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ChannelRequest_amountMsat(ctx context.Context, field graphql.CollectedField, obj *db.ChannelRequest) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ChannelRequest_amountMsat(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.ChannelRequest().AmountMsat(rctx, obj) @@ -3762,22 +3433,31 @@ func (ec *executionContext) _ChannelRequest_amountMsat(ctx context.Context, fiel return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _ChannelRequest_node(ctx context.Context, field graphql.CollectedField, obj *db.ChannelRequest) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ChannelRequest_amountMsat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ChannelRequest", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ChannelRequest_node(ctx context.Context, field graphql.CollectedField, obj *db.ChannelRequest) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ChannelRequest_node(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.ChannelRequest().Node(rctx, obj) @@ -3797,22 +3477,39 @@ func (ec *executionContext) _ChannelRequest_node(ctx context.Context, field grap return ec.marshalNNode2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐNode(ctx, field.Selections, res) } -func (ec *executionContext) _ChannelRequest_pendingChanId(ctx context.Context, field graphql.CollectedField, obj *db.ChannelRequest) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ChannelRequest_node(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ChannelRequest", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "pubkey": + return ec.fieldContext_Node_pubkey(ctx, field) + case "addr": + return ec.fieldContext_Node_addr(ctx, field) + case "alias": + return ec.fieldContext_Node_alias(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Node", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) _ChannelRequest_pendingChanId(ctx context.Context, field graphql.CollectedField, obj *db.ChannelRequest) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ChannelRequest_pendingChanId(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.ChannelRequest().PendingChanID(rctx, obj) @@ -3832,22 +3529,31 @@ func (ec *executionContext) _ChannelRequest_pendingChanId(ctx context.Context, f return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _ChannelRequest_scid(ctx context.Context, field graphql.CollectedField, obj *db.ChannelRequest) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ChannelRequest_pendingChanId(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ChannelRequest", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ChannelRequest_scid(ctx context.Context, field graphql.CollectedField, obj *db.ChannelRequest) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ChannelRequest_scid(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.ChannelRequest().Scid(rctx, obj) @@ -3867,22 +3573,31 @@ func (ec *executionContext) _ChannelRequest_scid(ctx context.Context, field grap return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _ChannelRequest_feeBaseMsat(ctx context.Context, field graphql.CollectedField, obj *db.ChannelRequest) (ret graphql.Marshaler) { +func (ec *executionContext) fieldContext_ChannelRequest_scid(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ChannelRequest", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + +func (ec *executionContext) _ChannelRequest_feeBaseMsat(ctx context.Context, field graphql.CollectedField, obj *db.ChannelRequest) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ChannelRequest_feeBaseMsat(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "ChannelRequest", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.FeeBaseMsat, nil @@ -3902,22 +3617,31 @@ func (ec *executionContext) _ChannelRequest_feeBaseMsat(ctx context.Context, fie return ec.marshalNInt2int64(ctx, field.Selections, res) } -func (ec *executionContext) _ChannelRequest_feeProportionalMillionths(ctx context.Context, field graphql.CollectedField, obj *db.ChannelRequest) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ChannelRequest_feeBaseMsat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ChannelRequest", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ChannelRequest_feeProportionalMillionths(ctx context.Context, field graphql.CollectedField, obj *db.ChannelRequest) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ChannelRequest_feeProportionalMillionths(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.FeeProportionalMillionths, nil @@ -3937,22 +3661,31 @@ func (ec *executionContext) _ChannelRequest_feeProportionalMillionths(ctx contex return ec.marshalNInt2int64(ctx, field.Selections, res) } -func (ec *executionContext) _ChannelRequest_cltvExpiryDelta(ctx context.Context, field graphql.CollectedField, obj *db.ChannelRequest) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ChannelRequest_feeProportionalMillionths(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ChannelRequest", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ChannelRequest_cltvExpiryDelta(ctx context.Context, field graphql.CollectedField, obj *db.ChannelRequest) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ChannelRequest_cltvExpiryDelta(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.CltvExpiryDelta, nil @@ -3972,22 +3705,31 @@ func (ec *executionContext) _ChannelRequest_cltvExpiryDelta(ctx context.Context, return ec.marshalNInt2int64(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_ChannelRequest_cltvExpiryDelta(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ChannelRequest", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Connector_id(ctx context.Context, field graphql.CollectedField, obj *db.Connector) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Connector_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Connector", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.ID, nil @@ -4007,22 +3749,31 @@ func (ec *executionContext) _Connector_id(ctx context.Context, field graphql.Col return ec.marshalNID2int64(ctx, field.Selections, res) } -func (ec *executionContext) _Connector_uid(ctx context.Context, field graphql.CollectedField, obj *db.Connector) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Connector_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Connector", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Connector_uid(ctx context.Context, field graphql.CollectedField, obj *db.Connector) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Connector_uid(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Uid, nil @@ -4042,22 +3793,31 @@ func (ec *executionContext) _Connector_uid(ctx context.Context, field graphql.Co return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Connector_uid(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Connector", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Connector_identifier(ctx context.Context, field graphql.CollectedField, obj *db.Connector) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Connector_identifier(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Connector", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Connector().Identifier(rctx, obj) @@ -4074,22 +3834,31 @@ func (ec *executionContext) _Connector_identifier(ctx context.Context, field gra return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } -func (ec *executionContext) _Connector_standard(ctx context.Context, field graphql.CollectedField, obj *db.Connector) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Connector_identifier(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Connector", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Connector_standard(ctx context.Context, field graphql.CollectedField, obj *db.Connector) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Connector_standard(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Connector().Standard(rctx, obj) @@ -4109,22 +3878,31 @@ func (ec *executionContext) _Connector_standard(ctx context.Context, field graph return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _Connector_format(ctx context.Context, field graphql.CollectedField, obj *db.Connector) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Connector_standard(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Connector", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Connector_format(ctx context.Context, field graphql.CollectedField, obj *db.Connector) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Connector_format(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Connector().Format(rctx, obj) @@ -4144,22 +3922,31 @@ func (ec *executionContext) _Connector_format(ctx context.Context, field graphql return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _Connector_powerType(ctx context.Context, field graphql.CollectedField, obj *db.Connector) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Connector_format(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Connector", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Connector_powerType(ctx context.Context, field graphql.CollectedField, obj *db.Connector) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Connector_powerType(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Connector().PowerType(rctx, obj) @@ -4179,22 +3966,31 @@ func (ec *executionContext) _Connector_powerType(ctx context.Context, field grap return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Connector_powerType(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Connector", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Connector_voltage(ctx context.Context, field graphql.CollectedField, obj *db.Connector) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Connector_voltage(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Connector", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Voltage, nil @@ -4214,22 +4010,31 @@ func (ec *executionContext) _Connector_voltage(ctx context.Context, field graphq return ec.marshalNInt2int32(ctx, field.Selections, res) } -func (ec *executionContext) _Connector_amperage(ctx context.Context, field graphql.CollectedField, obj *db.Connector) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Connector_voltage(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Connector", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Connector_amperage(ctx context.Context, field graphql.CollectedField, obj *db.Connector) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Connector_amperage(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Amperage, nil @@ -4249,22 +4054,31 @@ func (ec *executionContext) _Connector_amperage(ctx context.Context, field graph return ec.marshalNInt2int32(ctx, field.Selections, res) } -func (ec *executionContext) _Connector_wattage(ctx context.Context, field graphql.CollectedField, obj *db.Connector) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Connector_amperage(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Connector", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Connector_wattage(ctx context.Context, field graphql.CollectedField, obj *db.Connector) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Connector_wattage(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Wattage, nil @@ -4284,22 +4098,31 @@ func (ec *executionContext) _Connector_wattage(ctx context.Context, field graphq return ec.marshalNInt2int32(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Connector_wattage(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Connector", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Connector_tariffId(ctx context.Context, field graphql.CollectedField, obj *db.Connector) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Connector_tariffId(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Connector", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Connector().TariffID(rctx, obj) @@ -4316,22 +4139,31 @@ func (ec *executionContext) _Connector_tariffId(ctx context.Context, field graph return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } -func (ec *executionContext) _Connector_tariff(ctx context.Context, field graphql.CollectedField, obj *db.Connector) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Connector_tariffId(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Connector", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Connector_tariff(ctx context.Context, field graphql.CollectedField, obj *db.Connector) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Connector_tariff(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Connector().Tariff(rctx, obj) @@ -4348,22 +4180,51 @@ func (ec *executionContext) _Connector_tariff(ctx context.Context, field graphql return ec.marshalOTariff2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐTariff(ctx, field.Selections, res) } -func (ec *executionContext) _Connector_termsAndConditions(ctx context.Context, field graphql.CollectedField, obj *db.Connector) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Connector_tariff(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Connector", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Tariff_id(ctx, field) + case "uid": + return ec.fieldContext_Tariff_uid(ctx, field) + case "currency": + return ec.fieldContext_Tariff_currency(ctx, field) + case "currencyRate": + return ec.fieldContext_Tariff_currencyRate(ctx, field) + case "currencyRateMsat": + return ec.fieldContext_Tariff_currencyRateMsat(ctx, field) + case "commissionPercent": + return ec.fieldContext_Tariff_commissionPercent(ctx, field) + case "taxPercent": + return ec.fieldContext_Tariff_taxPercent(ctx, field) + case "elements": + return ec.fieldContext_Tariff_elements(ctx, field) + case "energyMix": + return ec.fieldContext_Tariff_energyMix(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Tariff", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) _Connector_termsAndConditions(ctx context.Context, field graphql.CollectedField, obj *db.Connector) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Connector_termsAndConditions(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Connector().TermsAndConditions(rctx, obj) @@ -4380,22 +4241,31 @@ func (ec *executionContext) _Connector_termsAndConditions(ctx context.Context, f return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } -func (ec *executionContext) _Connector_lastUpdated(ctx context.Context, field graphql.CollectedField, obj *db.Connector) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Connector_termsAndConditions(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Connector", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Connector_lastUpdated(ctx context.Context, field graphql.CollectedField, obj *db.Connector) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Connector_lastUpdated(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Connector().LastUpdated(rctx, obj) @@ -4415,22 +4285,31 @@ func (ec *executionContext) _Connector_lastUpdated(ctx context.Context, field gr return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Connector_lastUpdated(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Connector", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _CreateAuthentication_code(ctx context.Context, field graphql.CollectedField, obj *CreateAuthentication) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CreateAuthentication_code(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "CreateAuthentication", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Code, nil @@ -4450,22 +4329,31 @@ func (ec *executionContext) _CreateAuthentication_code(ctx context.Context, fiel return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _CreateAuthentication_lnUrl(ctx context.Context, field graphql.CollectedField, obj *CreateAuthentication) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_CreateAuthentication_code(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "CreateAuthentication", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _CreateAuthentication_lnUrl(ctx context.Context, field graphql.CollectedField, obj *CreateAuthentication) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_CreateAuthentication_lnUrl(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.LnURL, nil @@ -4485,22 +4373,31 @@ func (ec *executionContext) _CreateAuthentication_lnUrl(ctx context.Context, fie return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_CreateAuthentication_lnUrl(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "CreateAuthentication", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Credential_id(ctx context.Context, field graphql.CollectedField, obj *db.Credential) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Credential_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Credential", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.ID, nil @@ -4520,22 +4417,31 @@ func (ec *executionContext) _Credential_id(ctx context.Context, field graphql.Co return ec.marshalNID2int64(ctx, field.Selections, res) } -func (ec *executionContext) _Credential_url(ctx context.Context, field graphql.CollectedField, obj *db.Credential) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Credential_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Credential", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Credential_url(ctx context.Context, field graphql.CollectedField, obj *db.Credential) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Credential_url(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Url, nil @@ -4555,22 +4461,31 @@ func (ec *executionContext) _Credential_url(ctx context.Context, field graphql.C return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _Credential_countryCode(ctx context.Context, field graphql.CollectedField, obj *db.Credential) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Credential_url(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Credential", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Credential_countryCode(ctx context.Context, field graphql.CollectedField, obj *db.Credential) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Credential_countryCode(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.CountryCode, nil @@ -4590,22 +4505,31 @@ func (ec *executionContext) _Credential_countryCode(ctx context.Context, field g return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _Credential_partyId(ctx context.Context, field graphql.CollectedField, obj *db.Credential) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Credential_countryCode(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Credential", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Credential_partyId(ctx context.Context, field graphql.CollectedField, obj *db.Credential) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Credential_partyId(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.PartyID, nil @@ -4625,22 +4549,31 @@ func (ec *executionContext) _Credential_partyId(ctx context.Context, field graph return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _Credential_isHub(ctx context.Context, field graphql.CollectedField, obj *db.Credential) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Credential_partyId(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Credential", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Credential_isHub(ctx context.Context, field graphql.CollectedField, obj *db.Credential) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Credential_isHub(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.IsHub, nil @@ -4660,22 +4593,31 @@ func (ec *executionContext) _Credential_isHub(ctx context.Context, field graphql return ec.marshalNBoolean2bool(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Credential_isHub(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Credential", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _DisplayText_language(ctx context.Context, field graphql.CollectedField, obj *db.DisplayText) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DisplayText_language(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "DisplayText", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Language, nil @@ -4695,22 +4637,31 @@ func (ec *executionContext) _DisplayText_language(ctx context.Context, field gra return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _DisplayText_text(ctx context.Context, field graphql.CollectedField, obj *db.DisplayText) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_DisplayText_language(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "DisplayText", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _DisplayText_text(ctx context.Context, field graphql.CollectedField, obj *db.DisplayText) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_DisplayText_text(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Text, nil @@ -4730,22 +4681,31 @@ func (ec *executionContext) _DisplayText_text(ctx context.Context, field graphql return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_DisplayText_text(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "DisplayText", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _ElementRestriction_startTime(ctx context.Context, field graphql.CollectedField, obj *db.ElementRestriction) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ElementRestriction_startTime(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "ElementRestriction", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.ElementRestriction().StartTime(rctx, obj) @@ -4762,22 +4722,31 @@ func (ec *executionContext) _ElementRestriction_startTime(ctx context.Context, f return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } -func (ec *executionContext) _ElementRestriction_endTime(ctx context.Context, field graphql.CollectedField, obj *db.ElementRestriction) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ElementRestriction_startTime(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ElementRestriction", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ElementRestriction_endTime(ctx context.Context, field graphql.CollectedField, obj *db.ElementRestriction) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ElementRestriction_endTime(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.ElementRestriction().EndTime(rctx, obj) @@ -4794,22 +4763,31 @@ func (ec *executionContext) _ElementRestriction_endTime(ctx context.Context, fie return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } -func (ec *executionContext) _ElementRestriction_startDate(ctx context.Context, field graphql.CollectedField, obj *db.ElementRestriction) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ElementRestriction_endTime(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ElementRestriction", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ElementRestriction_startDate(ctx context.Context, field graphql.CollectedField, obj *db.ElementRestriction) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ElementRestriction_startDate(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.ElementRestriction().StartDate(rctx, obj) @@ -4826,22 +4804,31 @@ func (ec *executionContext) _ElementRestriction_startDate(ctx context.Context, f return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } -func (ec *executionContext) _ElementRestriction_endDate(ctx context.Context, field graphql.CollectedField, obj *db.ElementRestriction) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ElementRestriction_startDate(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ElementRestriction", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ElementRestriction_endDate(ctx context.Context, field graphql.CollectedField, obj *db.ElementRestriction) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ElementRestriction_endDate(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.ElementRestriction().EndDate(rctx, obj) @@ -4858,22 +4845,31 @@ func (ec *executionContext) _ElementRestriction_endDate(ctx context.Context, fie return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } -func (ec *executionContext) _ElementRestriction_minKwh(ctx context.Context, field graphql.CollectedField, obj *db.ElementRestriction) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ElementRestriction_endDate(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ElementRestriction", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ElementRestriction_minKwh(ctx context.Context, field graphql.CollectedField, obj *db.ElementRestriction) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ElementRestriction_minKwh(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.ElementRestriction().MinKwh(rctx, obj) @@ -4890,22 +4886,31 @@ func (ec *executionContext) _ElementRestriction_minKwh(ctx context.Context, fiel return ec.marshalOFloat2ᚖfloat64(ctx, field.Selections, res) } -func (ec *executionContext) _ElementRestriction_maxKwh(ctx context.Context, field graphql.CollectedField, obj *db.ElementRestriction) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ElementRestriction_minKwh(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ElementRestriction", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ElementRestriction_maxKwh(ctx context.Context, field graphql.CollectedField, obj *db.ElementRestriction) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ElementRestriction_maxKwh(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.ElementRestriction().MaxKwh(rctx, obj) @@ -4922,22 +4927,31 @@ func (ec *executionContext) _ElementRestriction_maxKwh(ctx context.Context, fiel return ec.marshalOFloat2ᚖfloat64(ctx, field.Selections, res) } -func (ec *executionContext) _ElementRestriction_minPower(ctx context.Context, field graphql.CollectedField, obj *db.ElementRestriction) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ElementRestriction_maxKwh(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ElementRestriction", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ElementRestriction_minPower(ctx context.Context, field graphql.CollectedField, obj *db.ElementRestriction) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ElementRestriction_minPower(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.ElementRestriction().MinPower(rctx, obj) @@ -4954,22 +4968,31 @@ func (ec *executionContext) _ElementRestriction_minPower(ctx context.Context, fi return ec.marshalOFloat2ᚖfloat64(ctx, field.Selections, res) } -func (ec *executionContext) _ElementRestriction_maxPower(ctx context.Context, field graphql.CollectedField, obj *db.ElementRestriction) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ElementRestriction_minPower(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ElementRestriction", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ElementRestriction_maxPower(ctx context.Context, field graphql.CollectedField, obj *db.ElementRestriction) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ElementRestriction_maxPower(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.ElementRestriction().MaxPower(rctx, obj) @@ -4986,22 +5009,31 @@ func (ec *executionContext) _ElementRestriction_maxPower(ctx context.Context, fi return ec.marshalOFloat2ᚖfloat64(ctx, field.Selections, res) } -func (ec *executionContext) _ElementRestriction_minDuration(ctx context.Context, field graphql.CollectedField, obj *db.ElementRestriction) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ElementRestriction_maxPower(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ElementRestriction", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ElementRestriction_minDuration(ctx context.Context, field graphql.CollectedField, obj *db.ElementRestriction) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ElementRestriction_minDuration(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.ElementRestriction().MinDuration(rctx, obj) @@ -5018,22 +5050,31 @@ func (ec *executionContext) _ElementRestriction_minDuration(ctx context.Context, return ec.marshalOInt2ᚖint(ctx, field.Selections, res) } -func (ec *executionContext) _ElementRestriction_maxDuration(ctx context.Context, field graphql.CollectedField, obj *db.ElementRestriction) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ElementRestriction_minDuration(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ElementRestriction", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ElementRestriction_maxDuration(ctx context.Context, field graphql.CollectedField, obj *db.ElementRestriction) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ElementRestriction_maxDuration(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.ElementRestriction().MaxDuration(rctx, obj) @@ -5050,22 +5091,31 @@ func (ec *executionContext) _ElementRestriction_maxDuration(ctx context.Context, return ec.marshalOInt2ᚖint(ctx, field.Selections, res) } -func (ec *executionContext) _ElementRestriction_dayOfWeek(ctx context.Context, field graphql.CollectedField, obj *db.ElementRestriction) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ElementRestriction_maxDuration(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ElementRestriction", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ElementRestriction_dayOfWeek(ctx context.Context, field graphql.CollectedField, obj *db.ElementRestriction) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ElementRestriction_dayOfWeek(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.ElementRestriction().DayOfWeek(rctx, obj) @@ -5082,22 +5132,31 @@ func (ec *executionContext) _ElementRestriction_dayOfWeek(ctx context.Context, f return ec.marshalOString2ᚕstringᚄ(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_ElementRestriction_dayOfWeek(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ElementRestriction", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _EmailSubscription_id(ctx context.Context, field graphql.CollectedField, obj *db.EmailSubscription) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_EmailSubscription_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "EmailSubscription", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.ID, nil @@ -5117,22 +5176,31 @@ func (ec *executionContext) _EmailSubscription_id(ctx context.Context, field gra return ec.marshalNID2int64(ctx, field.Selections, res) } -func (ec *executionContext) _EmailSubscription_email(ctx context.Context, field graphql.CollectedField, obj *db.EmailSubscription) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_EmailSubscription_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "EmailSubscription", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _EmailSubscription_email(ctx context.Context, field graphql.CollectedField, obj *db.EmailSubscription) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_EmailSubscription_email(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Email, nil @@ -5152,22 +5220,31 @@ func (ec *executionContext) _EmailSubscription_email(ctx context.Context, field return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _EmailSubscription_locale(ctx context.Context, field graphql.CollectedField, obj *db.EmailSubscription) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_EmailSubscription_email(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "EmailSubscription", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _EmailSubscription_locale(ctx context.Context, field graphql.CollectedField, obj *db.EmailSubscription) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_EmailSubscription_locale(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Locale, nil @@ -5187,22 +5264,31 @@ func (ec *executionContext) _EmailSubscription_locale(ctx context.Context, field return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _EmailSubscription_isVerified(ctx context.Context, field graphql.CollectedField, obj *db.EmailSubscription) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_EmailSubscription_locale(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "EmailSubscription", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _EmailSubscription_isVerified(ctx context.Context, field graphql.CollectedField, obj *db.EmailSubscription) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_EmailSubscription_isVerified(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.IsVerified, nil @@ -5222,22 +5308,31 @@ func (ec *executionContext) _EmailSubscription_isVerified(ctx context.Context, f return ec.marshalNBoolean2bool(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_EmailSubscription_isVerified(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "EmailSubscription", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _EnergyMix_isGreenEnergy(ctx context.Context, field graphql.CollectedField, obj *db.EnergyMix) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_EnergyMix_isGreenEnergy(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "EnergyMix", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.IsGreenEnergy, nil @@ -5257,22 +5352,31 @@ func (ec *executionContext) _EnergyMix_isGreenEnergy(ctx context.Context, field return ec.marshalNBoolean2bool(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_EnergyMix_isGreenEnergy(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "EnergyMix", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _EnergyMix_energySources(ctx context.Context, field graphql.CollectedField, obj *db.EnergyMix) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_EnergyMix_energySources(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "EnergyMix", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.EnergyMix().EnergySources(rctx, obj) @@ -5292,22 +5396,37 @@ func (ec *executionContext) _EnergyMix_energySources(ctx context.Context, field return ec.marshalNEnergySource2ᚕgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐEnergySourceᚄ(ctx, field.Selections, res) } -func (ec *executionContext) _EnergyMix_environmentalImpact(ctx context.Context, field graphql.CollectedField, obj *db.EnergyMix) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_EnergyMix_energySources(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "EnergyMix", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "source": + return ec.fieldContext_EnergySource_source(ctx, field) + case "percentage": + return ec.fieldContext_EnergySource_percentage(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type EnergySource", field.Name) + }, } + return fc, nil +} - ctx = graphql.WithFieldContext(ctx, fc) +func (ec *executionContext) _EnergyMix_environmentalImpact(ctx context.Context, field graphql.CollectedField, obj *db.EnergyMix) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_EnergyMix_environmentalImpact(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.EnergyMix().EnvironmentalImpact(rctx, obj) @@ -5327,22 +5446,37 @@ func (ec *executionContext) _EnergyMix_environmentalImpact(ctx context.Context, return ec.marshalNEnvironmentalImpact2ᚕgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐEnvironmentalImpactᚄ(ctx, field.Selections, res) } -func (ec *executionContext) _EnergyMix_supplierName(ctx context.Context, field graphql.CollectedField, obj *db.EnergyMix) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_EnergyMix_environmentalImpact(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "EnergyMix", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "source": + return ec.fieldContext_EnvironmentalImpact_source(ctx, field) + case "amount": + return ec.fieldContext_EnvironmentalImpact_amount(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type EnvironmentalImpact", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) _EnergyMix_supplierName(ctx context.Context, field graphql.CollectedField, obj *db.EnergyMix) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_EnergyMix_supplierName(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.EnergyMix().SupplierName(rctx, obj) @@ -5359,22 +5493,31 @@ func (ec *executionContext) _EnergyMix_supplierName(ctx context.Context, field g return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } -func (ec *executionContext) _EnergyMix_energyProductName(ctx context.Context, field graphql.CollectedField, obj *db.EnergyMix) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_EnergyMix_supplierName(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "EnergyMix", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _EnergyMix_energyProductName(ctx context.Context, field graphql.CollectedField, obj *db.EnergyMix) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_EnergyMix_energyProductName(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.EnergyMix().EnergyProductName(rctx, obj) @@ -5391,22 +5534,31 @@ func (ec *executionContext) _EnergyMix_energyProductName(ctx context.Context, fi return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_EnergyMix_energyProductName(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "EnergyMix", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _EnergySource_source(ctx context.Context, field graphql.CollectedField, obj *db.EnergySource) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_EnergySource_source(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "EnergySource", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.EnergySource().Source(rctx, obj) @@ -5426,22 +5578,31 @@ func (ec *executionContext) _EnergySource_source(ctx context.Context, field grap return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_EnergySource_source(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "EnergySource", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _EnergySource_percentage(ctx context.Context, field graphql.CollectedField, obj *db.EnergySource) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_EnergySource_percentage(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "EnergySource", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Percentage, nil @@ -5461,22 +5622,31 @@ func (ec *executionContext) _EnergySource_percentage(ctx context.Context, field return ec.marshalNFloat2float64(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_EnergySource_percentage(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "EnergySource", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _EnvironmentalImpact_source(ctx context.Context, field graphql.CollectedField, obj *db.EnvironmentalImpact) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_EnvironmentalImpact_source(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "EnvironmentalImpact", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.EnvironmentalImpact().Source(rctx, obj) @@ -5496,22 +5666,31 @@ func (ec *executionContext) _EnvironmentalImpact_source(ctx context.Context, fie return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_EnvironmentalImpact_source(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "EnvironmentalImpact", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _EnvironmentalImpact_amount(ctx context.Context, field graphql.CollectedField, obj *db.EnvironmentalImpact) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_EnvironmentalImpact_amount(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "EnvironmentalImpact", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Amount, nil @@ -5531,22 +5710,31 @@ func (ec *executionContext) _EnvironmentalImpact_amount(ctx context.Context, fie return ec.marshalNFloat2float64(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_EnvironmentalImpact_amount(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "EnvironmentalImpact", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Evse_id(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evse_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Evse", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.ID, nil @@ -5566,22 +5754,31 @@ func (ec *executionContext) _Evse_id(ctx context.Context, field graphql.Collecte return ec.marshalNID2int64(ctx, field.Selections, res) } -func (ec *executionContext) _Evse_uid(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Evse_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Evse", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Evse_uid(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evse_uid(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Uid, nil @@ -5601,22 +5798,31 @@ func (ec *executionContext) _Evse_uid(ctx context.Context, field graphql.Collect return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Evse_uid(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Evse", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Evse_identifier(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evse_identifier(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Evse", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Evse().Identifier(rctx, obj) @@ -5633,22 +5839,31 @@ func (ec *executionContext) _Evse_identifier(ctx context.Context, field graphql. return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } -func (ec *executionContext) _Evse_status(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Evse_identifier(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Evse", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Evse_status(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evse_status(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Evse().Status(rctx, obj) @@ -5668,22 +5883,31 @@ func (ec *executionContext) _Evse_status(ctx context.Context, field graphql.Coll return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _Evse_statusSchedule(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Evse_status(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Evse", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Evse_statusSchedule(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evse_statusSchedule(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Evse().StatusSchedule(rctx, obj) @@ -5703,22 +5927,39 @@ func (ec *executionContext) _Evse_statusSchedule(ctx context.Context, field grap return ec.marshalNStatusSchedule2ᚕgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐStatusScheduleᚄ(ctx, field.Selections, res) } -func (ec *executionContext) _Evse_capabilities(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Evse_statusSchedule(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Evse", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "periodBegin": + return ec.fieldContext_StatusSchedule_periodBegin(ctx, field) + case "periodEnd": + return ec.fieldContext_StatusSchedule_periodEnd(ctx, field) + case "status": + return ec.fieldContext_StatusSchedule_status(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type StatusSchedule", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) _Evse_capabilities(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evse_capabilities(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Evse().Capabilities(rctx, obj) @@ -5738,22 +5979,37 @@ func (ec *executionContext) _Evse_capabilities(ctx context.Context, field graphq return ec.marshalNTextDescription2ᚕgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐTextDescriptionᚄ(ctx, field.Selections, res) } -func (ec *executionContext) _Evse_connectors(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Evse_capabilities(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Evse", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "text": + return ec.fieldContext_TextDescription_text(ctx, field) + case "description": + return ec.fieldContext_TextDescription_description(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type TextDescription", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) _Evse_connectors(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evse_connectors(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Evse().Connectors(rctx, obj) @@ -5773,22 +6029,59 @@ func (ec *executionContext) _Evse_connectors(ctx context.Context, field graphql. return ec.marshalNConnector2ᚕgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐConnectorᚄ(ctx, field.Selections, res) } -func (ec *executionContext) _Evse_floorLevel(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Evse_connectors(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Evse", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Connector_id(ctx, field) + case "uid": + return ec.fieldContext_Connector_uid(ctx, field) + case "identifier": + return ec.fieldContext_Connector_identifier(ctx, field) + case "standard": + return ec.fieldContext_Connector_standard(ctx, field) + case "format": + return ec.fieldContext_Connector_format(ctx, field) + case "powerType": + return ec.fieldContext_Connector_powerType(ctx, field) + case "voltage": + return ec.fieldContext_Connector_voltage(ctx, field) + case "amperage": + return ec.fieldContext_Connector_amperage(ctx, field) + case "wattage": + return ec.fieldContext_Connector_wattage(ctx, field) + case "tariffId": + return ec.fieldContext_Connector_tariffId(ctx, field) + case "tariff": + return ec.fieldContext_Connector_tariff(ctx, field) + case "termsAndConditions": + return ec.fieldContext_Connector_termsAndConditions(ctx, field) + case "lastUpdated": + return ec.fieldContext_Connector_lastUpdated(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Connector", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) _Evse_floorLevel(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evse_floorLevel(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Evse().FloorLevel(rctx, obj) @@ -5805,22 +6098,31 @@ func (ec *executionContext) _Evse_floorLevel(ctx context.Context, field graphql. return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } -func (ec *executionContext) _Evse_geom(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Evse_floorLevel(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Evse", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Evse_geom(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evse_geom(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Evse().Geom(rctx, obj) @@ -5837,22 +6139,31 @@ func (ec *executionContext) _Evse_geom(ctx context.Context, field graphql.Collec return ec.marshalOGeometry2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋgeomᚐGeometry4326(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Evse_geom(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Evse", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Geometry does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Evse_isRemoteCapable(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evse_isRemoteCapable(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Evse", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.IsRemoteCapable, nil @@ -5872,22 +6183,31 @@ func (ec *executionContext) _Evse_isRemoteCapable(ctx context.Context, field gra return ec.marshalNBoolean2bool(ctx, field.Selections, res) } -func (ec *executionContext) _Evse_isRfidCapable(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Evse_isRemoteCapable(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Evse", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Evse_isRfidCapable(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evse_isRfidCapable(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.IsRfidCapable, nil @@ -5907,22 +6227,31 @@ func (ec *executionContext) _Evse_isRfidCapable(ctx context.Context, field graph return ec.marshalNBoolean2bool(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Evse_isRfidCapable(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Evse", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Evse_physicalReference(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evse_physicalReference(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Evse", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Evse().PhysicalReference(rctx, obj) @@ -5939,22 +6268,31 @@ func (ec *executionContext) _Evse_physicalReference(ctx context.Context, field g return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } -func (ec *executionContext) _Evse_directions(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Evse_physicalReference(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Evse", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Evse_directions(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evse_directions(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Evse().Directions(rctx, obj) @@ -5974,22 +6312,37 @@ func (ec *executionContext) _Evse_directions(ctx context.Context, field graphql. return ec.marshalNDisplayText2ᚕgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐDisplayTextᚄ(ctx, field.Selections, res) } -func (ec *executionContext) _Evse_parkingRestrictions(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Evse_directions(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Evse", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "language": + return ec.fieldContext_DisplayText_language(ctx, field) + case "text": + return ec.fieldContext_DisplayText_text(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type DisplayText", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) _Evse_parkingRestrictions(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evse_parkingRestrictions(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Evse().ParkingRestrictions(rctx, obj) @@ -6009,22 +6362,37 @@ func (ec *executionContext) _Evse_parkingRestrictions(ctx context.Context, field return ec.marshalNTextDescription2ᚕgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐTextDescriptionᚄ(ctx, field.Selections, res) } -func (ec *executionContext) _Evse_images(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Evse_parkingRestrictions(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Evse", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "text": + return ec.fieldContext_TextDescription_text(ctx, field) + case "description": + return ec.fieldContext_TextDescription_description(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type TextDescription", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) _Evse_images(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evse_images(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Evse().Images(rctx, obj) @@ -6044,22 +6412,45 @@ func (ec *executionContext) _Evse_images(ctx context.Context, field graphql.Coll return ec.marshalNImage2ᚕgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐImageᚄ(ctx, field.Selections, res) } -func (ec *executionContext) _Evse_lastUpdated(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Evse_images(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Evse", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "url": + return ec.fieldContext_Image_url(ctx, field) + case "thumbnail": + return ec.fieldContext_Image_thumbnail(ctx, field) + case "category": + return ec.fieldContext_Image_category(ctx, field) + case "type": + return ec.fieldContext_Image_type(ctx, field) + case "width": + return ec.fieldContext_Image_width(ctx, field) + case "height": + return ec.fieldContext_Image_height(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Image", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) _Evse_lastUpdated(ctx context.Context, field graphql.CollectedField, obj *db.Evse) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Evse_lastUpdated(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Evse().LastUpdated(rctx, obj) @@ -6079,22 +6470,31 @@ func (ec *executionContext) _Evse_lastUpdated(ctx context.Context, field graphql return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Evse_lastUpdated(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Evse", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _ExceptionalPeriod_periodBegin(ctx context.Context, field graphql.CollectedField, obj *db.ExceptionalPeriod) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ExceptionalPeriod_periodBegin(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "ExceptionalPeriod", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.ExceptionalPeriod().PeriodBegin(rctx, obj) @@ -6114,22 +6514,31 @@ func (ec *executionContext) _ExceptionalPeriod_periodBegin(ctx context.Context, return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _ExceptionalPeriod_periodEnd(ctx context.Context, field graphql.CollectedField, obj *db.ExceptionalPeriod) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ExceptionalPeriod_periodBegin(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ExceptionalPeriod", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ExceptionalPeriod_periodEnd(ctx context.Context, field graphql.CollectedField, obj *db.ExceptionalPeriod) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ExceptionalPeriod_periodEnd(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.ExceptionalPeriod().PeriodEnd(rctx, obj) @@ -6149,22 +6558,31 @@ func (ec *executionContext) _ExceptionalPeriod_periodEnd(ctx context.Context, fi return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_ExceptionalPeriod_periodEnd(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ExceptionalPeriod", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _ExchangeAuthentication_token(ctx context.Context, field graphql.CollectedField, obj *ExchangeAuthentication) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ExchangeAuthentication_token(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "ExchangeAuthentication", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Token, nil @@ -6184,22 +6602,31 @@ func (ec *executionContext) _ExchangeAuthentication_token(ctx context.Context, f return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_ExchangeAuthentication_token(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ExchangeAuthentication", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Geolocation_latitude(ctx context.Context, field graphql.CollectedField, obj *Geolocation) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Geolocation_latitude(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Geolocation", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Latitude, nil @@ -6219,22 +6646,31 @@ func (ec *executionContext) _Geolocation_latitude(ctx context.Context, field gra return ec.marshalNFloat2float64(ctx, field.Selections, res) } -func (ec *executionContext) _Geolocation_longitude(ctx context.Context, field graphql.CollectedField, obj *Geolocation) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Geolocation_latitude(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Geolocation", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Geolocation_longitude(ctx context.Context, field graphql.CollectedField, obj *Geolocation) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Geolocation_longitude(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Longitude, nil @@ -6254,22 +6690,31 @@ func (ec *executionContext) _Geolocation_longitude(ctx context.Context, field gr return ec.marshalNFloat2float64(ctx, field.Selections, res) } -func (ec *executionContext) _Geolocation_name(ctx context.Context, field graphql.CollectedField, obj *Geolocation) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Geolocation_longitude(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Geolocation", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Geolocation_name(ctx context.Context, field graphql.CollectedField, obj *Geolocation) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Geolocation_name(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Name, nil @@ -6286,22 +6731,31 @@ func (ec *executionContext) _Geolocation_name(ctx context.Context, field graphql return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Geolocation_name(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Geolocation", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Image_url(ctx context.Context, field graphql.CollectedField, obj *db.Image) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Image_url(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Image", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Url, nil @@ -6321,22 +6775,31 @@ func (ec *executionContext) _Image_url(ctx context.Context, field graphql.Collec return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Image_url(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Image", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Image_thumbnail(ctx context.Context, field graphql.CollectedField, obj *db.Image) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Image_thumbnail(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Image", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Image().Thumbnail(rctx, obj) @@ -6353,22 +6816,31 @@ func (ec *executionContext) _Image_thumbnail(ctx context.Context, field graphql. return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } -func (ec *executionContext) _Image_category(ctx context.Context, field graphql.CollectedField, obj *db.Image) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Image_thumbnail(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Image", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Image_category(ctx context.Context, field graphql.CollectedField, obj *db.Image) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Image_category(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Image().Category(rctx, obj) @@ -6388,22 +6860,31 @@ func (ec *executionContext) _Image_category(ctx context.Context, field graphql.C return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Image_category(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Image", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Image_type(ctx context.Context, field graphql.CollectedField, obj *db.Image) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Image_type(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Image", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Type, nil @@ -6423,22 +6904,31 @@ func (ec *executionContext) _Image_type(ctx context.Context, field graphql.Colle return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Image_type(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Image", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Image_width(ctx context.Context, field graphql.CollectedField, obj *db.Image) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Image_width(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Image", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Image().Width(rctx, obj) @@ -6455,22 +6945,31 @@ func (ec *executionContext) _Image_width(ctx context.Context, field graphql.Coll return ec.marshalOInt2ᚖint(ctx, field.Selections, res) } -func (ec *executionContext) _Image_height(ctx context.Context, field graphql.CollectedField, obj *db.Image) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Image_width(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Image", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Image_height(ctx context.Context, field graphql.CollectedField, obj *db.Image) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Image_height(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Image().Height(rctx, obj) @@ -6487,22 +6986,31 @@ func (ec *executionContext) _Image_height(ctx context.Context, field graphql.Col return ec.marshalOInt2ᚖint(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Image_height(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Image", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _InvoiceRequest_id(ctx context.Context, field graphql.CollectedField, obj *db.InvoiceRequest) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_InvoiceRequest_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "InvoiceRequest", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.ID, nil @@ -6522,22 +7030,31 @@ func (ec *executionContext) _InvoiceRequest_id(ctx context.Context, field graphq return ec.marshalNID2int64(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_InvoiceRequest_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "InvoiceRequest", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _InvoiceRequest_promotion(ctx context.Context, field graphql.CollectedField, obj *db.InvoiceRequest) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_InvoiceRequest_promotion(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "InvoiceRequest", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.InvoiceRequest().Promotion(rctx, obj) @@ -6557,22 +7074,37 @@ func (ec *executionContext) _InvoiceRequest_promotion(ctx context.Context, field return ec.marshalNPromotion2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐPromotion(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_InvoiceRequest_promotion(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "InvoiceRequest", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "code": + return ec.fieldContext_Promotion_code(ctx, field) + case "description": + return ec.fieldContext_Promotion_description(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Promotion", field.Name) + }, + } + return fc, nil +} + func (ec *executionContext) _InvoiceRequest_currency(ctx context.Context, field graphql.CollectedField, obj *db.InvoiceRequest) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_InvoiceRequest_currency(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "InvoiceRequest", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Currency, nil @@ -6592,22 +7124,31 @@ func (ec *executionContext) _InvoiceRequest_currency(ctx context.Context, field return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _InvoiceRequest_memo(ctx context.Context, field graphql.CollectedField, obj *db.InvoiceRequest) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_InvoiceRequest_currency(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "InvoiceRequest", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _InvoiceRequest_memo(ctx context.Context, field graphql.CollectedField, obj *db.InvoiceRequest) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_InvoiceRequest_memo(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Memo, nil @@ -6627,22 +7168,31 @@ func (ec *executionContext) _InvoiceRequest_memo(ctx context.Context, field grap return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_InvoiceRequest_memo(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "InvoiceRequest", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _InvoiceRequest_priceFiat(ctx context.Context, field graphql.CollectedField, obj *db.InvoiceRequest) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_InvoiceRequest_priceFiat(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "InvoiceRequest", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.InvoiceRequest().PriceFiat(rctx, obj) @@ -6659,22 +7209,31 @@ func (ec *executionContext) _InvoiceRequest_priceFiat(ctx context.Context, field return ec.marshalOFloat2ᚖfloat64(ctx, field.Selections, res) } -func (ec *executionContext) _InvoiceRequest_priceMsat(ctx context.Context, field graphql.CollectedField, obj *db.InvoiceRequest) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_InvoiceRequest_priceFiat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "InvoiceRequest", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _InvoiceRequest_priceMsat(ctx context.Context, field graphql.CollectedField, obj *db.InvoiceRequest) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_InvoiceRequest_priceMsat(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.InvoiceRequest().PriceMsat(rctx, obj) @@ -6691,22 +7250,31 @@ func (ec *executionContext) _InvoiceRequest_priceMsat(ctx context.Context, field return ec.marshalOInt2ᚖint(ctx, field.Selections, res) } -func (ec *executionContext) _InvoiceRequest_commissionFiat(ctx context.Context, field graphql.CollectedField, obj *db.InvoiceRequest) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_InvoiceRequest_priceMsat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "InvoiceRequest", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _InvoiceRequest_commissionFiat(ctx context.Context, field graphql.CollectedField, obj *db.InvoiceRequest) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_InvoiceRequest_commissionFiat(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.InvoiceRequest().CommissionFiat(rctx, obj) @@ -6723,22 +7291,31 @@ func (ec *executionContext) _InvoiceRequest_commissionFiat(ctx context.Context, return ec.marshalOFloat2ᚖfloat64(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_InvoiceRequest_commissionFiat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "InvoiceRequest", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _InvoiceRequest_commissionMsat(ctx context.Context, field graphql.CollectedField, obj *db.InvoiceRequest) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_InvoiceRequest_commissionMsat(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "InvoiceRequest", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.InvoiceRequest().CommissionMsat(rctx, obj) @@ -6755,22 +7332,31 @@ func (ec *executionContext) _InvoiceRequest_commissionMsat(ctx context.Context, return ec.marshalOInt2ᚖint(ctx, field.Selections, res) } -func (ec *executionContext) _InvoiceRequest_taxFiat(ctx context.Context, field graphql.CollectedField, obj *db.InvoiceRequest) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_InvoiceRequest_commissionMsat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "InvoiceRequest", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _InvoiceRequest_taxFiat(ctx context.Context, field graphql.CollectedField, obj *db.InvoiceRequest) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_InvoiceRequest_taxFiat(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.InvoiceRequest().TaxFiat(rctx, obj) @@ -6787,22 +7373,31 @@ func (ec *executionContext) _InvoiceRequest_taxFiat(ctx context.Context, field g return ec.marshalOFloat2ᚖfloat64(ctx, field.Selections, res) } -func (ec *executionContext) _InvoiceRequest_taxMsat(ctx context.Context, field graphql.CollectedField, obj *db.InvoiceRequest) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_InvoiceRequest_taxFiat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "InvoiceRequest", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _InvoiceRequest_taxMsat(ctx context.Context, field graphql.CollectedField, obj *db.InvoiceRequest) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_InvoiceRequest_taxMsat(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.InvoiceRequest().TaxMsat(rctx, obj) @@ -6819,22 +7414,31 @@ func (ec *executionContext) _InvoiceRequest_taxMsat(ctx context.Context, field g return ec.marshalOInt2ᚖint(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_InvoiceRequest_taxMsat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "InvoiceRequest", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _InvoiceRequest_totalFiat(ctx context.Context, field graphql.CollectedField, obj *db.InvoiceRequest) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_InvoiceRequest_totalFiat(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "InvoiceRequest", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.TotalFiat, nil @@ -6854,22 +7458,31 @@ func (ec *executionContext) _InvoiceRequest_totalFiat(ctx context.Context, field return ec.marshalNFloat2float64(ctx, field.Selections, res) } -func (ec *executionContext) _InvoiceRequest_totalMsat(ctx context.Context, field graphql.CollectedField, obj *db.InvoiceRequest) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_InvoiceRequest_totalFiat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "InvoiceRequest", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _InvoiceRequest_totalMsat(ctx context.Context, field graphql.CollectedField, obj *db.InvoiceRequest) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_InvoiceRequest_totalMsat(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.TotalMsat, nil @@ -6889,22 +7502,31 @@ func (ec *executionContext) _InvoiceRequest_totalMsat(ctx context.Context, field return ec.marshalNInt2int64(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_InvoiceRequest_totalMsat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "InvoiceRequest", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _ListLocation_uid(ctx context.Context, field graphql.CollectedField, obj *ListLocation) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ListLocation_uid(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "ListLocation", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.UID, nil @@ -6924,22 +7546,31 @@ func (ec *executionContext) _ListLocation_uid(ctx context.Context, field graphql return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _ListLocation_name(ctx context.Context, field graphql.CollectedField, obj *ListLocation) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ListLocation_uid(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ListLocation", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ListLocation_name(ctx context.Context, field graphql.CollectedField, obj *ListLocation) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ListLocation_name(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Name, nil @@ -6959,22 +7590,31 @@ func (ec *executionContext) _ListLocation_name(ctx context.Context, field graphq return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _ListLocation_geom(ctx context.Context, field graphql.CollectedField, obj *ListLocation) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ListLocation_name(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ListLocation", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ListLocation_geom(ctx context.Context, field graphql.CollectedField, obj *ListLocation) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ListLocation_geom(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Geom, nil @@ -6994,22 +7634,31 @@ func (ec *executionContext) _ListLocation_geom(ctx context.Context, field graphq return ec.marshalNGeometry2githubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋgeomᚐGeometry4326(ctx, field.Selections, res) } -func (ec *executionContext) _ListLocation_availableEvses(ctx context.Context, field graphql.CollectedField, obj *ListLocation) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ListLocation_geom(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ListLocation", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Geometry does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ListLocation_availableEvses(ctx context.Context, field graphql.CollectedField, obj *ListLocation) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ListLocation_availableEvses(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.AvailableEvses, nil @@ -7029,22 +7678,31 @@ func (ec *executionContext) _ListLocation_availableEvses(ctx context.Context, fi return ec.marshalNInt2int(ctx, field.Selections, res) } -func (ec *executionContext) _ListLocation_totalEvses(ctx context.Context, field graphql.CollectedField, obj *ListLocation) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ListLocation_availableEvses(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ListLocation", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ListLocation_totalEvses(ctx context.Context, field graphql.CollectedField, obj *ListLocation) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ListLocation_totalEvses(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.TotalEvses, nil @@ -7064,22 +7722,31 @@ func (ec *executionContext) _ListLocation_totalEvses(ctx context.Context, field return ec.marshalNInt2int(ctx, field.Selections, res) } -func (ec *executionContext) _ListLocation_isRemoteCapable(ctx context.Context, field graphql.CollectedField, obj *ListLocation) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ListLocation_totalEvses(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ListLocation", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ListLocation_isRemoteCapable(ctx context.Context, field graphql.CollectedField, obj *ListLocation) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ListLocation_isRemoteCapable(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.IsRemoteCapable, nil @@ -7099,22 +7766,31 @@ func (ec *executionContext) _ListLocation_isRemoteCapable(ctx context.Context, f return ec.marshalNBoolean2bool(ctx, field.Selections, res) } -func (ec *executionContext) _ListLocation_isRfidCapable(ctx context.Context, field graphql.CollectedField, obj *ListLocation) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_ListLocation_isRemoteCapable(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "ListLocation", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _ListLocation_isRfidCapable(ctx context.Context, field graphql.CollectedField, obj *ListLocation) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ListLocation_isRfidCapable(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.IsRfidCapable, nil @@ -7134,22 +7810,31 @@ func (ec *executionContext) _ListLocation_isRfidCapable(ctx context.Context, fie return ec.marshalNBoolean2bool(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_ListLocation_isRfidCapable(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ListLocation", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Location_id(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Location", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.ID, nil @@ -7169,22 +7854,31 @@ func (ec *executionContext) _Location_id(ctx context.Context, field graphql.Coll return ec.marshalNID2int64(ctx, field.Selections, res) } -func (ec *executionContext) _Location_uid(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Location_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Location", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Location_uid(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_uid(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Uid, nil @@ -7204,22 +7898,31 @@ func (ec *executionContext) _Location_uid(ctx context.Context, field graphql.Col return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Location_uid(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Location", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Location_type(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_type(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Location", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Location().Type(rctx, obj) @@ -7239,22 +7942,31 @@ func (ec *executionContext) _Location_type(ctx context.Context, field graphql.Co return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _Location_name(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Location_type(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Location", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Location_name(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_name(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Location().Name(rctx, obj) @@ -7271,22 +7983,31 @@ func (ec *executionContext) _Location_name(ctx context.Context, field graphql.Co return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Location_name(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Location", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Location_address(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_address(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Location", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Address, nil @@ -7306,22 +8027,31 @@ func (ec *executionContext) _Location_address(ctx context.Context, field graphql return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _Location_city(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Location_address(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Location", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Location_city(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_city(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.City, nil @@ -7341,22 +8071,31 @@ func (ec *executionContext) _Location_city(ctx context.Context, field graphql.Co return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _Location_postalCode(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Location_city(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Location", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Location_postalCode(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_postalCode(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.PostalCode, nil @@ -7376,22 +8115,31 @@ func (ec *executionContext) _Location_postalCode(ctx context.Context, field grap return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _Location_country(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Location_postalCode(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Location", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Location_country(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_country(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Country, nil @@ -7411,22 +8159,31 @@ func (ec *executionContext) _Location_country(ctx context.Context, field graphql return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _Location_geom(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Location_country(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Location", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Location_geom(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_geom(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Geom, nil @@ -7446,22 +8203,31 @@ func (ec *executionContext) _Location_geom(ctx context.Context, field graphql.Co return ec.marshalNGeometry2githubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋgeomᚐGeometry4326(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Location_geom(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Location", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Geometry does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Location_relatedLocations(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_relatedLocations(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Location", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Location().RelatedLocations(rctx, obj) @@ -7481,22 +8247,39 @@ func (ec *executionContext) _Location_relatedLocations(ctx context.Context, fiel return ec.marshalNAddtionalGeoLocation2ᚕgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐAddtionalGeoLocationᚄ(ctx, field.Selections, res) } -func (ec *executionContext) _Location_evses(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Location_relatedLocations(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Location", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "latitude": + return ec.fieldContext_AddtionalGeoLocation_latitude(ctx, field) + case "longitude": + return ec.fieldContext_AddtionalGeoLocation_longitude(ctx, field) + case "name": + return ec.fieldContext_AddtionalGeoLocation_name(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type AddtionalGeoLocation", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) _Location_evses(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_evses(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Location().Evses(rctx, obj) @@ -7516,22 +8299,65 @@ func (ec *executionContext) _Location_evses(ctx context.Context, field graphql.C return ec.marshalNEvse2ᚕgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐEvseᚄ(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Location_evses(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Location", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Evse_id(ctx, field) + case "uid": + return ec.fieldContext_Evse_uid(ctx, field) + case "identifier": + return ec.fieldContext_Evse_identifier(ctx, field) + case "status": + return ec.fieldContext_Evse_status(ctx, field) + case "statusSchedule": + return ec.fieldContext_Evse_statusSchedule(ctx, field) + case "capabilities": + return ec.fieldContext_Evse_capabilities(ctx, field) + case "connectors": + return ec.fieldContext_Evse_connectors(ctx, field) + case "floorLevel": + return ec.fieldContext_Evse_floorLevel(ctx, field) + case "geom": + return ec.fieldContext_Evse_geom(ctx, field) + case "isRemoteCapable": + return ec.fieldContext_Evse_isRemoteCapable(ctx, field) + case "isRfidCapable": + return ec.fieldContext_Evse_isRfidCapable(ctx, field) + case "physicalReference": + return ec.fieldContext_Evse_physicalReference(ctx, field) + case "directions": + return ec.fieldContext_Evse_directions(ctx, field) + case "parkingRestrictions": + return ec.fieldContext_Evse_parkingRestrictions(ctx, field) + case "images": + return ec.fieldContext_Evse_images(ctx, field) + case "lastUpdated": + return ec.fieldContext_Evse_lastUpdated(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Evse", field.Name) + }, + } + return fc, nil +} + func (ec *executionContext) _Location_availableEvses(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_availableEvses(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Location", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.AvailableEvses, nil @@ -7551,22 +8377,31 @@ func (ec *executionContext) _Location_availableEvses(ctx context.Context, field return ec.marshalNInt2int32(ctx, field.Selections, res) } -func (ec *executionContext) _Location_totalEvses(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Location_availableEvses(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Location", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Location_totalEvses(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_totalEvses(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.TotalEvses, nil @@ -7586,22 +8421,31 @@ func (ec *executionContext) _Location_totalEvses(ctx context.Context, field grap return ec.marshalNInt2int32(ctx, field.Selections, res) } -func (ec *executionContext) _Location_isRemoteCapable(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Location_totalEvses(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Location", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Location_isRemoteCapable(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_isRemoteCapable(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.IsRemoteCapable, nil @@ -7621,22 +8465,31 @@ func (ec *executionContext) _Location_isRemoteCapable(ctx context.Context, field return ec.marshalNBoolean2bool(ctx, field.Selections, res) } -func (ec *executionContext) _Location_isRfidCapable(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Location_isRemoteCapable(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Location", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Location_isRfidCapable(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_isRfidCapable(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.IsRfidCapable, nil @@ -7656,22 +8509,31 @@ func (ec *executionContext) _Location_isRfidCapable(ctx context.Context, field g return ec.marshalNBoolean2bool(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Location_isRfidCapable(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Location", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Location_directions(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_directions(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Location", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Location().Directions(rctx, obj) @@ -7691,31 +8553,46 @@ func (ec *executionContext) _Location_directions(ctx context.Context, field grap return ec.marshalNDisplayText2ᚕgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐDisplayTextᚄ(ctx, field.Selections, res) } -func (ec *executionContext) _Location_operator(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Location_directions(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Location", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "language": + return ec.fieldContext_DisplayText_language(ctx, field) + case "text": + return ec.fieldContext_DisplayText_text(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type DisplayText", field.Name) + }, } + return fc, nil +} - ctx = graphql.WithFieldContext(ctx, fc) - resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { - ctx = rctx // use context from middleware stack in children - return ec.resolvers.Location().Operator(rctx, obj) - }) +func (ec *executionContext) _Location_operator(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_operator(ctx, field) if err != nil { - ec.Error(ctx, err) return graphql.Null } - if resTmp == nil { + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Location().Operator(rctx, obj) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { return graphql.Null } res := resTmp.(*db.BusinessDetail) @@ -7723,22 +8600,39 @@ func (ec *executionContext) _Location_operator(ctx context.Context, field graphq return ec.marshalOBusinessDetail2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐBusinessDetail(ctx, field.Selections, res) } -func (ec *executionContext) _Location_suboperator(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Location_operator(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Location", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "name": + return ec.fieldContext_BusinessDetail_name(ctx, field) + case "website": + return ec.fieldContext_BusinessDetail_website(ctx, field) + case "logo": + return ec.fieldContext_BusinessDetail_logo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type BusinessDetail", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) _Location_suboperator(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_suboperator(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Location().Suboperator(rctx, obj) @@ -7755,22 +8649,39 @@ func (ec *executionContext) _Location_suboperator(ctx context.Context, field gra return ec.marshalOBusinessDetail2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐBusinessDetail(ctx, field.Selections, res) } -func (ec *executionContext) _Location_owner(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Location_suboperator(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Location", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "name": + return ec.fieldContext_BusinessDetail_name(ctx, field) + case "website": + return ec.fieldContext_BusinessDetail_website(ctx, field) + case "logo": + return ec.fieldContext_BusinessDetail_logo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type BusinessDetail", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) _Location_owner(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_owner(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Location().Owner(rctx, obj) @@ -7787,22 +8698,39 @@ func (ec *executionContext) _Location_owner(ctx context.Context, field graphql.C return ec.marshalOBusinessDetail2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐBusinessDetail(ctx, field.Selections, res) } -func (ec *executionContext) _Location_facilities(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Location_owner(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Location", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "name": + return ec.fieldContext_BusinessDetail_name(ctx, field) + case "website": + return ec.fieldContext_BusinessDetail_website(ctx, field) + case "logo": + return ec.fieldContext_BusinessDetail_logo(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type BusinessDetail", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) _Location_facilities(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_facilities(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Location().Facilities(rctx, obj) @@ -7822,22 +8750,37 @@ func (ec *executionContext) _Location_facilities(ctx context.Context, field grap return ec.marshalNTextDescription2ᚕgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐTextDescriptionᚄ(ctx, field.Selections, res) } -func (ec *executionContext) _Location_timeZone(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Location_facilities(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Location", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "text": + return ec.fieldContext_TextDescription_text(ctx, field) + case "description": + return ec.fieldContext_TextDescription_description(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type TextDescription", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) _Location_timeZone(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_timeZone(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Location().TimeZone(rctx, obj) @@ -7854,22 +8797,31 @@ func (ec *executionContext) _Location_timeZone(ctx context.Context, field graphq return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } -func (ec *executionContext) _Location_openingTime(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Location_timeZone(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Location", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Location_openingTime(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_openingTime(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Location().OpeningTime(rctx, obj) @@ -7886,22 +8838,41 @@ func (ec *executionContext) _Location_openingTime(ctx context.Context, field gra return ec.marshalOOpeningTime2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐOpeningTime(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Location_openingTime(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Location", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "regularHours": + return ec.fieldContext_OpeningTime_regularHours(ctx, field) + case "twentyfourseven": + return ec.fieldContext_OpeningTime_twentyfourseven(ctx, field) + case "exceptionalOpenings": + return ec.fieldContext_OpeningTime_exceptionalOpenings(ctx, field) + case "exceptionalClosings": + return ec.fieldContext_OpeningTime_exceptionalClosings(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type OpeningTime", field.Name) + }, + } + return fc, nil +} + func (ec *executionContext) _Location_chargingWhenClosed(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_chargingWhenClosed(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Location", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.ChargingWhenClosed, nil @@ -7921,22 +8892,31 @@ func (ec *executionContext) _Location_chargingWhenClosed(ctx context.Context, fi return ec.marshalNBoolean2bool(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Location_chargingWhenClosed(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Location", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Location_images(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_images(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Location", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Location().Images(rctx, obj) @@ -7956,22 +8936,45 @@ func (ec *executionContext) _Location_images(ctx context.Context, field graphql. return ec.marshalNImage2ᚕgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐImageᚄ(ctx, field.Selections, res) } -func (ec *executionContext) _Location_energyMix(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Location_images(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Location", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "url": + return ec.fieldContext_Image_url(ctx, field) + case "thumbnail": + return ec.fieldContext_Image_thumbnail(ctx, field) + case "category": + return ec.fieldContext_Image_category(ctx, field) + case "type": + return ec.fieldContext_Image_type(ctx, field) + case "width": + return ec.fieldContext_Image_width(ctx, field) + case "height": + return ec.fieldContext_Image_height(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Image", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) _Location_energyMix(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_energyMix(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Location().EnergyMix(rctx, obj) @@ -7988,22 +8991,43 @@ func (ec *executionContext) _Location_energyMix(ctx context.Context, field graph return ec.marshalOEnergyMix2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐEnergyMix(ctx, field.Selections, res) } -func (ec *executionContext) _Location_lastUpdated(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Location_energyMix(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Location", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "isGreenEnergy": + return ec.fieldContext_EnergyMix_isGreenEnergy(ctx, field) + case "energySources": + return ec.fieldContext_EnergyMix_energySources(ctx, field) + case "environmentalImpact": + return ec.fieldContext_EnergyMix_environmentalImpact(ctx, field) + case "supplierName": + return ec.fieldContext_EnergyMix_supplierName(ctx, field) + case "energyProductName": + return ec.fieldContext_EnergyMix_energyProductName(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type EnergyMix", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) _Location_lastUpdated(ctx context.Context, field graphql.CollectedField, obj *db.Location) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Location_lastUpdated(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Location().LastUpdated(rctx, obj) @@ -8023,32 +9047,34 @@ func (ec *executionContext) _Location_lastUpdated(ctx context.Context, field gra return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _Mutation_createAuthentication(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ - Object: "Mutation", +func (ec *executionContext) fieldContext_Location_lastUpdated(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Location", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} - ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Mutation_createAuthentication_args(ctx, rawArgs) +func (ec *executionContext) _Mutation_createAuthentication(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_createAuthentication(ctx, field) if err != nil { - ec.Error(ctx, err) return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return ec.resolvers.Mutation().CreateAuthentication(rctx, args["action"].(AuthenticationAction)) + return ec.resolvers.Mutation().CreateAuthentication(rctx, fc.Args["action"].(AuthenticationAction)) }) if err != nil { ec.Error(ctx, err) @@ -8065,32 +9091,51 @@ func (ec *executionContext) _Mutation_createAuthentication(ctx context.Context, return ec.marshalNCreateAuthentication2ᚖgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐCreateAuthentication(ctx, field.Selections, res) } -func (ec *executionContext) _Mutation_exchangeAuthentication(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Mutation_createAuthentication(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Mutation", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "code": + return ec.fieldContext_CreateAuthentication_code(ctx, field) + case "lnUrl": + return ec.fieldContext_CreateAuthentication_lnUrl(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type CreateAuthentication", field.Name) + }, } - + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Mutation_exchangeAuthentication_args(ctx, rawArgs) - if err != nil { + if fc.Args, err = ec.field_Mutation_createAuthentication_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { ec.Error(ctx, err) + return + } + return fc, nil +} + +func (ec *executionContext) _Mutation_exchangeAuthentication(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_exchangeAuthentication(ctx, field) + if err != nil { return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return ec.resolvers.Mutation().ExchangeAuthentication(rctx, args["code"].(string)) + return ec.resolvers.Mutation().ExchangeAuthentication(rctx, fc.Args["code"].(string)) }) if err != nil { ec.Error(ctx, err) @@ -8107,40 +9152,57 @@ func (ec *executionContext) _Mutation_exchangeAuthentication(ctx context.Context return ec.marshalNExchangeAuthentication2ᚖgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐExchangeAuthentication(ctx, field.Selections, res) } -func (ec *executionContext) _Mutation_createChannelRequest(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Mutation_exchangeAuthentication(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Mutation", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "token": + return ec.fieldContext_ExchangeAuthentication_token(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ExchangeAuthentication", field.Name) + }, } - + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Mutation_createChannelRequest_args(ctx, rawArgs) - if err != nil { + if fc.Args, err = ec.field_Mutation_exchangeAuthentication_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { ec.Error(ctx, err) - return graphql.Null + return } - fc.Args = args - resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { - ctx = rctx // use context from middleware stack in children - return ec.resolvers.Mutation().CreateChannelRequest(rctx, args["input"].(CreateChannelRequestInput)) - }) + return fc, nil +} + +func (ec *executionContext) _Mutation_createChannelRequest(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_createChannelRequest(ctx, field) if err != nil { - ec.Error(ctx, err) return graphql.Null } - if resTmp == nil { - if !graphql.HasFieldError(ctx, fc) { - ec.Errorf(ctx, "must not be null") + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().CreateChannelRequest(rctx, fc.Args["input"].(CreateChannelRequestInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") } return graphql.Null } @@ -8149,32 +9211,67 @@ func (ec *executionContext) _Mutation_createChannelRequest(ctx context.Context, return ec.marshalNChannelRequest2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐChannelRequest(ctx, field.Selections, res) } -func (ec *executionContext) _Mutation_startSession(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Mutation_createChannelRequest(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Mutation", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_ChannelRequest_id(ctx, field) + case "paymentHash": + return ec.fieldContext_ChannelRequest_paymentHash(ctx, field) + case "paymentAddr": + return ec.fieldContext_ChannelRequest_paymentAddr(ctx, field) + case "amountMsat": + return ec.fieldContext_ChannelRequest_amountMsat(ctx, field) + case "node": + return ec.fieldContext_ChannelRequest_node(ctx, field) + case "pendingChanId": + return ec.fieldContext_ChannelRequest_pendingChanId(ctx, field) + case "scid": + return ec.fieldContext_ChannelRequest_scid(ctx, field) + case "feeBaseMsat": + return ec.fieldContext_ChannelRequest_feeBaseMsat(ctx, field) + case "feeProportionalMillionths": + return ec.fieldContext_ChannelRequest_feeProportionalMillionths(ctx, field) + case "cltvExpiryDelta": + return ec.fieldContext_ChannelRequest_cltvExpiryDelta(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ChannelRequest", field.Name) + }, } - + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Mutation_startSession_args(ctx, rawArgs) - if err != nil { + if fc.Args, err = ec.field_Mutation_createChannelRequest_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { ec.Error(ctx, err) + return + } + return fc, nil +} + +func (ec *executionContext) _Mutation_startSession(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_startSession(ctx, field) + if err != nil { return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return ec.resolvers.Mutation().StartSession(rctx, args["input"].(StartSessionInput)) + return ec.resolvers.Mutation().StartSession(rctx, fc.Args["input"].(StartSessionInput)) }) if err != nil { ec.Error(ctx, err) @@ -8191,32 +9288,59 @@ func (ec *executionContext) _Mutation_startSession(ctx context.Context, field gr return ec.marshalNStartSession2ᚖgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐStartSession(ctx, field.Selections, res) } -func (ec *executionContext) _Mutation_stopSession(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Mutation_startSession(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Mutation", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_StartSession_id(ctx, field) + case "status": + return ec.fieldContext_StartSession_status(ctx, field) + case "authorizationId": + return ec.fieldContext_StartSession_authorizationId(ctx, field) + case "verificationKey": + return ec.fieldContext_StartSession_verificationKey(ctx, field) + case "locationUid": + return ec.fieldContext_StartSession_locationUid(ctx, field) + case "evseUid": + return ec.fieldContext_StartSession_evseUid(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type StartSession", field.Name) + }, } - + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Mutation_stopSession_args(ctx, rawArgs) - if err != nil { + if fc.Args, err = ec.field_Mutation_startSession_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { ec.Error(ctx, err) + return + } + return fc, nil +} + +func (ec *executionContext) _Mutation_stopSession(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_stopSession(ctx, field) + if err != nil { return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return ec.resolvers.Mutation().StopSession(rctx, args["input"].(StopSessionInput)) + return ec.resolvers.Mutation().StopSession(rctx, fc.Args["input"].(StopSessionInput)) }) if err != nil { ec.Error(ctx, err) @@ -8233,32 +9357,53 @@ func (ec *executionContext) _Mutation_stopSession(ctx context.Context, field gra return ec.marshalNStopSession2ᚖgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐStopSession(ctx, field.Selections, res) } -func (ec *executionContext) _Mutation_createCredential(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Mutation_stopSession(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Mutation", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_StopSession_id(ctx, field) + case "status": + return ec.fieldContext_StopSession_status(ctx, field) + case "sessionUid": + return ec.fieldContext_StopSession_sessionUid(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type StopSession", field.Name) + }, } - + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Mutation_createCredential_args(ctx, rawArgs) - if err != nil { + if fc.Args, err = ec.field_Mutation_stopSession_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { ec.Error(ctx, err) + return + } + return fc, nil +} + +func (ec *executionContext) _Mutation_createCredential(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_createCredential(ctx, field) + if err != nil { return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return ec.resolvers.Mutation().CreateCredential(rctx, args["input"].(CreateCredentialInput)) + return ec.resolvers.Mutation().CreateCredential(rctx, fc.Args["input"].(CreateCredentialInput)) }) if err != nil { ec.Error(ctx, err) @@ -8275,32 +9420,116 @@ func (ec *executionContext) _Mutation_createCredential(ctx context.Context, fiel return ec.marshalNCredential2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐCredential(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Mutation_createCredential(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Credential_id(ctx, field) + case "url": + return ec.fieldContext_Credential_url(ctx, field) + case "countryCode": + return ec.fieldContext_Credential_countryCode(ctx, field) + case "partyId": + return ec.fieldContext_Credential_partyId(ctx, field) + case "isHub": + return ec.fieldContext_Credential_isHub(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Credential", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_createCredential_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return + } + return fc, nil +} + func (ec *executionContext) _Mutation_registerCredential(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_registerCredential(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return ec.resolvers.Mutation().RegisterCredential(rctx, fc.Args["input"].(RegisterCredentialInput)) + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + if !graphql.HasFieldError(ctx, fc) { + ec.Errorf(ctx, "must not be null") + } + return graphql.Null + } + res := resTmp.(*ResultID) + fc.Result = res + return ec.marshalNResultId2ᚖgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐResultID(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_Mutation_registerCredential(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Mutation", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_ResultId_id(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ResultId", field.Name) + }, } - + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Mutation_registerCredential_args(ctx, rawArgs) - if err != nil { + if fc.Args, err = ec.field_Mutation_registerCredential_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { ec.Error(ctx, err) + return + } + return fc, nil +} + +func (ec *executionContext) _Mutation_syncCredential(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_syncCredential(ctx, field) + if err != nil { return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return ec.resolvers.Mutation().RegisterCredential(rctx, args["input"].(RegisterCredentialInput)) + return ec.resolvers.Mutation().SyncCredential(rctx, fc.Args["input"].(SyncCredentialInput)) }) if err != nil { ec.Error(ctx, err) @@ -8317,32 +9546,49 @@ func (ec *executionContext) _Mutation_registerCredential(ctx context.Context, fi return ec.marshalNResultId2ᚖgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐResultID(ctx, field.Selections, res) } -func (ec *executionContext) _Mutation_unregisterCredential(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Mutation_syncCredential(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Mutation", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_ResultId_id(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ResultId", field.Name) + }, } - + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Mutation_unregisterCredential_args(ctx, rawArgs) - if err != nil { + if fc.Args, err = ec.field_Mutation_syncCredential_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { ec.Error(ctx, err) + return + } + return fc, nil +} + +func (ec *executionContext) _Mutation_unregisterCredential(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_unregisterCredential(ctx, field) + if err != nil { return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return ec.resolvers.Mutation().UnregisterCredential(rctx, args["input"].(UnregisterCredentialInput)) + return ec.resolvers.Mutation().UnregisterCredential(rctx, fc.Args["input"].(UnregisterCredentialInput)) }) if err != nil { ec.Error(ctx, err) @@ -8359,32 +9605,49 @@ func (ec *executionContext) _Mutation_unregisterCredential(ctx context.Context, return ec.marshalNResultId2ᚖgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐResultID(ctx, field.Selections, res) } -func (ec *executionContext) _Mutation_createEmailSubscription(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Mutation_unregisterCredential(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Mutation", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_ResultId_id(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ResultId", field.Name) + }, } - + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Mutation_createEmailSubscription_args(ctx, rawArgs) - if err != nil { + if fc.Args, err = ec.field_Mutation_unregisterCredential_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { ec.Error(ctx, err) + return + } + return fc, nil +} + +func (ec *executionContext) _Mutation_createEmailSubscription(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_createEmailSubscription(ctx, field) + if err != nil { return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return ec.resolvers.Mutation().CreateEmailSubscription(rctx, args["input"].(CreateEmailSubscriptionInput)) + return ec.resolvers.Mutation().CreateEmailSubscription(rctx, fc.Args["input"].(CreateEmailSubscriptionInput)) }) if err != nil { ec.Error(ctx, err) @@ -8401,32 +9664,55 @@ func (ec *executionContext) _Mutation_createEmailSubscription(ctx context.Contex return ec.marshalNEmailSubscription2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐEmailSubscription(ctx, field.Selections, res) } -func (ec *executionContext) _Mutation_verifyEmailSubscription(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Mutation_createEmailSubscription(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Mutation", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_EmailSubscription_id(ctx, field) + case "email": + return ec.fieldContext_EmailSubscription_email(ctx, field) + case "locale": + return ec.fieldContext_EmailSubscription_locale(ctx, field) + case "isVerified": + return ec.fieldContext_EmailSubscription_isVerified(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type EmailSubscription", field.Name) + }, } - + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Mutation_verifyEmailSubscription_args(ctx, rawArgs) - if err != nil { + if fc.Args, err = ec.field_Mutation_createEmailSubscription_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { ec.Error(ctx, err) + return + } + return fc, nil +} + +func (ec *executionContext) _Mutation_verifyEmailSubscription(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_verifyEmailSubscription(ctx, field) + if err != nil { return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return ec.resolvers.Mutation().VerifyEmailSubscription(rctx, args["input"].(VerifyEmailSubscriptionInput)) + return ec.resolvers.Mutation().VerifyEmailSubscription(rctx, fc.Args["input"].(VerifyEmailSubscriptionInput)) }) if err != nil { ec.Error(ctx, err) @@ -8443,32 +9729,55 @@ func (ec *executionContext) _Mutation_verifyEmailSubscription(ctx context.Contex return ec.marshalNEmailSubscription2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐEmailSubscription(ctx, field.Selections, res) } -func (ec *executionContext) _Mutation_updateInvoiceRequest(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Mutation_verifyEmailSubscription(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Mutation", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_EmailSubscription_id(ctx, field) + case "email": + return ec.fieldContext_EmailSubscription_email(ctx, field) + case "locale": + return ec.fieldContext_EmailSubscription_locale(ctx, field) + case "isVerified": + return ec.fieldContext_EmailSubscription_isVerified(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type EmailSubscription", field.Name) + }, } - + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Mutation_updateInvoiceRequest_args(ctx, rawArgs) - if err != nil { + if fc.Args, err = ec.field_Mutation_verifyEmailSubscription_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { ec.Error(ctx, err) + return + } + return fc, nil +} + +func (ec *executionContext) _Mutation_updateInvoiceRequest(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_updateInvoiceRequest(ctx, field) + if err != nil { return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return ec.resolvers.Mutation().UpdateInvoiceRequest(rctx, args["input"].(UpdateInvoiceRequestInput)) + return ec.resolvers.Mutation().UpdateInvoiceRequest(rctx, fc.Args["input"].(UpdateInvoiceRequestInput)) }) if err != nil { ec.Error(ctx, err) @@ -8485,32 +9794,71 @@ func (ec *executionContext) _Mutation_updateInvoiceRequest(ctx context.Context, return ec.marshalNInvoiceRequest2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐInvoiceRequest(ctx, field.Selections, res) } -func (ec *executionContext) _Mutation_publishLocation(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Mutation_updateInvoiceRequest(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Mutation", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_InvoiceRequest_id(ctx, field) + case "promotion": + return ec.fieldContext_InvoiceRequest_promotion(ctx, field) + case "currency": + return ec.fieldContext_InvoiceRequest_currency(ctx, field) + case "memo": + return ec.fieldContext_InvoiceRequest_memo(ctx, field) + case "priceFiat": + return ec.fieldContext_InvoiceRequest_priceFiat(ctx, field) + case "priceMsat": + return ec.fieldContext_InvoiceRequest_priceMsat(ctx, field) + case "commissionFiat": + return ec.fieldContext_InvoiceRequest_commissionFiat(ctx, field) + case "commissionMsat": + return ec.fieldContext_InvoiceRequest_commissionMsat(ctx, field) + case "taxFiat": + return ec.fieldContext_InvoiceRequest_taxFiat(ctx, field) + case "taxMsat": + return ec.fieldContext_InvoiceRequest_taxMsat(ctx, field) + case "totalFiat": + return ec.fieldContext_InvoiceRequest_totalFiat(ctx, field) + case "totalMsat": + return ec.fieldContext_InvoiceRequest_totalMsat(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type InvoiceRequest", field.Name) + }, } - + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Mutation_publishLocation_args(ctx, rawArgs) - if err != nil { + if fc.Args, err = ec.field_Mutation_updateInvoiceRequest_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { ec.Error(ctx, err) + return + } + return fc, nil +} + +func (ec *executionContext) _Mutation_publishLocation(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_publishLocation(ctx, field) + if err != nil { return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return ec.resolvers.Mutation().PublishLocation(rctx, args["input"].(PublishLocationInput)) + return ec.resolvers.Mutation().PublishLocation(rctx, fc.Args["input"].(PublishLocationInput)) }) if err != nil { ec.Error(ctx, err) @@ -8527,32 +9875,49 @@ func (ec *executionContext) _Mutation_publishLocation(ctx context.Context, field return ec.marshalNResultOk2ᚖgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐResultOk(ctx, field.Selections, res) } -func (ec *executionContext) _Mutation_createReferral(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Mutation_publishLocation(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Mutation", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "ok": + return ec.fieldContext_ResultOk_ok(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ResultOk", field.Name) + }, } - + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Mutation_createReferral_args(ctx, rawArgs) - if err != nil { + if fc.Args, err = ec.field_Mutation_publishLocation_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { ec.Error(ctx, err) + return + } + return fc, nil +} + +func (ec *executionContext) _Mutation_createReferral(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_createReferral(ctx, field) + if err != nil { return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return ec.resolvers.Mutation().CreateReferral(rctx, args["input"].(CreateReferralInput)) + return ec.resolvers.Mutation().CreateReferral(rctx, fc.Args["input"].(CreateReferralInput)) }) if err != nil { ec.Error(ctx, err) @@ -8569,32 +9934,49 @@ func (ec *executionContext) _Mutation_createReferral(ctx context.Context, field return ec.marshalNResultId2ᚖgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐResultID(ctx, field.Selections, res) } -func (ec *executionContext) _Mutation_createUser(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Mutation_createReferral(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Mutation", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_ResultId_id(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ResultId", field.Name) + }, } - + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Mutation_createUser_args(ctx, rawArgs) - if err != nil { + if fc.Args, err = ec.field_Mutation_createReferral_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { ec.Error(ctx, err) + return + } + return fc, nil +} + +func (ec *executionContext) _Mutation_createUser(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_createUser(ctx, field) + if err != nil { return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return ec.resolvers.Mutation().CreateUser(rctx, args["input"].(CreateUserInput)) + return ec.resolvers.Mutation().CreateUser(rctx, fc.Args["input"].(CreateUserInput)) }) if err != nil { ec.Error(ctx, err) @@ -8611,32 +9993,55 @@ func (ec *executionContext) _Mutation_createUser(ctx context.Context, field grap return ec.marshalNUser2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐUser(ctx, field.Selections, res) } -func (ec *executionContext) _Mutation_updateUser(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Mutation_createUser(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Mutation", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_User_id(ctx, field) + case "pubkey": + return ec.fieldContext_User_pubkey(ctx, field) + case "deviceToken": + return ec.fieldContext_User_deviceToken(ctx, field) + case "referralCode": + return ec.fieldContext_User_referralCode(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type User", field.Name) + }, } - + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Mutation_updateUser_args(ctx, rawArgs) - if err != nil { + if fc.Args, err = ec.field_Mutation_createUser_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { ec.Error(ctx, err) + return + } + return fc, nil +} + +func (ec *executionContext) _Mutation_updateUser(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Mutation_updateUser(ctx, field) + if err != nil { return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return ec.resolvers.Mutation().UpdateUser(rctx, args["input"].(UpdateUserInput)) + return ec.resolvers.Mutation().UpdateUser(rctx, fc.Args["input"].(UpdateUserInput)) }) if err != nil { ec.Error(ctx, err) @@ -8653,22 +10058,52 @@ func (ec *executionContext) _Mutation_updateUser(ctx context.Context, field grap return ec.marshalNUser2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐUser(ctx, field.Selections, res) } -func (ec *executionContext) _Node_pubkey(ctx context.Context, field graphql.CollectedField, obj *db.Node) (ret graphql.Marshaler) { +func (ec *executionContext) fieldContext_Mutation_updateUser(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Mutation", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_User_id(ctx, field) + case "pubkey": + return ec.fieldContext_User_pubkey(ctx, field) + case "deviceToken": + return ec.fieldContext_User_deviceToken(ctx, field) + case "referralCode": + return ec.fieldContext_User_referralCode(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type User", field.Name) + }, + } defer func() { if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null + err = ec.Recover(ctx, r) + ec.Error(ctx, err) } }() - fc := &graphql.FieldContext{ - Object: "Node", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Mutation_updateUser_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return } + return fc, nil +} +func (ec *executionContext) _Node_pubkey(ctx context.Context, field graphql.CollectedField, obj *db.Node) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Node_pubkey(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Pubkey, nil @@ -8688,22 +10123,31 @@ func (ec *executionContext) _Node_pubkey(ctx context.Context, field graphql.Coll return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Node_pubkey(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Node", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Node_addr(ctx context.Context, field graphql.CollectedField, obj *db.Node) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Node_addr(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Node", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Node().Addr(rctx, obj) @@ -8723,22 +10167,31 @@ func (ec *executionContext) _Node_addr(ctx context.Context, field graphql.Collec return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Node_addr(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Node", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Node_alias(ctx context.Context, field graphql.CollectedField, obj *db.Node) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Node_alias(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Node", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Alias, nil @@ -8758,22 +10211,31 @@ func (ec *executionContext) _Node_alias(ctx context.Context, field graphql.Colle return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Node_alias(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Node", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _OpeningTime_regularHours(ctx context.Context, field graphql.CollectedField, obj *db.OpeningTime) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_OpeningTime_regularHours(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "OpeningTime", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.OpeningTime().RegularHours(rctx, obj) @@ -8793,22 +10255,39 @@ func (ec *executionContext) _OpeningTime_regularHours(ctx context.Context, field return ec.marshalNRegularHour2ᚕgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐRegularHourᚄ(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_OpeningTime_regularHours(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "OpeningTime", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "weekday": + return ec.fieldContext_RegularHour_weekday(ctx, field) + case "periodBegin": + return ec.fieldContext_RegularHour_periodBegin(ctx, field) + case "periodEnd": + return ec.fieldContext_RegularHour_periodEnd(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type RegularHour", field.Name) + }, + } + return fc, nil +} + func (ec *executionContext) _OpeningTime_twentyfourseven(ctx context.Context, field graphql.CollectedField, obj *db.OpeningTime) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_OpeningTime_twentyfourseven(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "OpeningTime", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Twentyfourseven, nil @@ -8828,22 +10307,31 @@ func (ec *executionContext) _OpeningTime_twentyfourseven(ctx context.Context, fi return ec.marshalNBoolean2bool(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_OpeningTime_twentyfourseven(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "OpeningTime", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _OpeningTime_exceptionalOpenings(ctx context.Context, field graphql.CollectedField, obj *db.OpeningTime) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_OpeningTime_exceptionalOpenings(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "OpeningTime", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.OpeningTime().ExceptionalOpenings(rctx, obj) @@ -8863,22 +10351,37 @@ func (ec *executionContext) _OpeningTime_exceptionalOpenings(ctx context.Context return ec.marshalNExceptionalPeriod2ᚕgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐExceptionalPeriodᚄ(ctx, field.Selections, res) } -func (ec *executionContext) _OpeningTime_exceptionalClosings(ctx context.Context, field graphql.CollectedField, obj *db.OpeningTime) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_OpeningTime_exceptionalOpenings(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "OpeningTime", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "periodBegin": + return ec.fieldContext_ExceptionalPeriod_periodBegin(ctx, field) + case "periodEnd": + return ec.fieldContext_ExceptionalPeriod_periodEnd(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ExceptionalPeriod", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) _OpeningTime_exceptionalClosings(ctx context.Context, field graphql.CollectedField, obj *db.OpeningTime) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_OpeningTime_exceptionalClosings(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.OpeningTime().ExceptionalClosings(rctx, obj) @@ -8893,27 +10396,42 @@ func (ec *executionContext) _OpeningTime_exceptionalClosings(ctx context.Context } return graphql.Null } - res := resTmp.([]db.ExceptionalPeriod) - fc.Result = res - return ec.marshalNExceptionalPeriod2ᚕgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐExceptionalPeriodᚄ(ctx, field.Selections, res) + res := resTmp.([]db.ExceptionalPeriod) + fc.Result = res + return ec.marshalNExceptionalPeriod2ᚕgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐExceptionalPeriodᚄ(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_OpeningTime_exceptionalClosings(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "OpeningTime", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "periodBegin": + return ec.fieldContext_ExceptionalPeriod_periodBegin(ctx, field) + case "periodEnd": + return ec.fieldContext_ExceptionalPeriod_periodEnd(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ExceptionalPeriod", field.Name) + }, + } + return fc, nil } func (ec *executionContext) _PriceComponent_type(ctx context.Context, field graphql.CollectedField, obj *db.PriceComponent) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_PriceComponent_type(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "PriceComponent", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.PriceComponent().Type(rctx, obj) @@ -8933,22 +10451,31 @@ func (ec *executionContext) _PriceComponent_type(ctx context.Context, field grap return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_PriceComponent_type(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "PriceComponent", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _PriceComponent_price(ctx context.Context, field graphql.CollectedField, obj *db.PriceComponent) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_PriceComponent_price(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "PriceComponent", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Price, nil @@ -8968,22 +10495,31 @@ func (ec *executionContext) _PriceComponent_price(ctx context.Context, field gra return ec.marshalNFloat2float64(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_PriceComponent_price(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "PriceComponent", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _PriceComponent_priceMsat(ctx context.Context, field graphql.CollectedField, obj *db.PriceComponent) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_PriceComponent_priceMsat(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "PriceComponent", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.PriceComponent().PriceMsat(rctx, obj) @@ -9003,22 +10539,31 @@ func (ec *executionContext) _PriceComponent_priceMsat(ctx context.Context, field return ec.marshalNInt2int(ctx, field.Selections, res) } -func (ec *executionContext) _PriceComponent_commissionMsat(ctx context.Context, field graphql.CollectedField, obj *db.PriceComponent) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_PriceComponent_priceMsat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "PriceComponent", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _PriceComponent_commissionMsat(ctx context.Context, field graphql.CollectedField, obj *db.PriceComponent) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_PriceComponent_commissionMsat(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.PriceComponent().CommissionMsat(rctx, obj) @@ -9038,22 +10583,31 @@ func (ec *executionContext) _PriceComponent_commissionMsat(ctx context.Context, return ec.marshalNInt2int(ctx, field.Selections, res) } -func (ec *executionContext) _PriceComponent_taxMsat(ctx context.Context, field graphql.CollectedField, obj *db.PriceComponent) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_PriceComponent_commissionMsat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "PriceComponent", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _PriceComponent_taxMsat(ctx context.Context, field graphql.CollectedField, obj *db.PriceComponent) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_PriceComponent_taxMsat(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.PriceComponent().TaxMsat(rctx, obj) @@ -9070,22 +10624,31 @@ func (ec *executionContext) _PriceComponent_taxMsat(ctx context.Context, field g return ec.marshalOInt2ᚖint(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_PriceComponent_taxMsat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "PriceComponent", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _PriceComponent_stepSize(ctx context.Context, field graphql.CollectedField, obj *db.PriceComponent) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_PriceComponent_stepSize(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "PriceComponent", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.StepSize, nil @@ -9105,22 +10668,31 @@ func (ec *executionContext) _PriceComponent_stepSize(ctx context.Context, field return ec.marshalNInt2int32(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_PriceComponent_stepSize(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "PriceComponent", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Promotion_code(ctx context.Context, field graphql.CollectedField, obj *db.Promotion) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Promotion_code(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Promotion", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Code, nil @@ -9140,22 +10712,31 @@ func (ec *executionContext) _Promotion_code(ctx context.Context, field graphql.C return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _Promotion_description(ctx context.Context, field graphql.CollectedField, obj *db.Promotion) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Promotion_code(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Promotion", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Promotion_description(ctx context.Context, field graphql.CollectedField, obj *db.Promotion) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Promotion_description(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Description, nil @@ -9175,32 +10756,34 @@ func (ec *executionContext) _Promotion_description(ctx context.Context, field gr return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Promotion_description(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Promotion", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Query_verifyAuthentication(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_verifyAuthentication(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Query", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Query_verifyAuthentication_args(ctx, rawArgs) - if err != nil { - ec.Error(ctx, err) - return graphql.Null - } - fc.Args = args resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return ec.resolvers.Query().VerifyAuthentication(rctx, args["code"].(string)) + return ec.resolvers.Query().VerifyAuthentication(rctx, fc.Args["code"].(string)) }) if err != nil { ec.Error(ctx, err) @@ -9217,22 +10800,46 @@ func (ec *executionContext) _Query_verifyAuthentication(ctx context.Context, fie return ec.marshalNVerifyAuthentication2ᚖgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐVerifyAuthentication(ctx, field.Selections, res) } -func (ec *executionContext) _Query_listInvoiceRequests(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Query_verifyAuthentication(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Query", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "verified": + return ec.fieldContext_VerifyAuthentication_verified(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type VerifyAuthentication", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Query_verifyAuthentication_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return } + return fc, nil +} +func (ec *executionContext) _Query_listInvoiceRequests(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_listInvoiceRequests(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Query().ListInvoiceRequests(rctx) @@ -9252,32 +10859,60 @@ func (ec *executionContext) _Query_listInvoiceRequests(ctx context.Context, fiel return ec.marshalNInvoiceRequest2ᚕgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐInvoiceRequestᚄ(ctx, field.Selections, res) } -func (ec *executionContext) _Query_getLocation(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Query_listInvoiceRequests(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Query", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_InvoiceRequest_id(ctx, field) + case "promotion": + return ec.fieldContext_InvoiceRequest_promotion(ctx, field) + case "currency": + return ec.fieldContext_InvoiceRequest_currency(ctx, field) + case "memo": + return ec.fieldContext_InvoiceRequest_memo(ctx, field) + case "priceFiat": + return ec.fieldContext_InvoiceRequest_priceFiat(ctx, field) + case "priceMsat": + return ec.fieldContext_InvoiceRequest_priceMsat(ctx, field) + case "commissionFiat": + return ec.fieldContext_InvoiceRequest_commissionFiat(ctx, field) + case "commissionMsat": + return ec.fieldContext_InvoiceRequest_commissionMsat(ctx, field) + case "taxFiat": + return ec.fieldContext_InvoiceRequest_taxFiat(ctx, field) + case "taxMsat": + return ec.fieldContext_InvoiceRequest_taxMsat(ctx, field) + case "totalFiat": + return ec.fieldContext_InvoiceRequest_totalFiat(ctx, field) + case "totalMsat": + return ec.fieldContext_InvoiceRequest_totalMsat(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type InvoiceRequest", field.Name) + }, } + return fc, nil +} - ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Query_getLocation_args(ctx, rawArgs) +func (ec *executionContext) _Query_getLocation(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_getLocation(ctx, field) if err != nil { - ec.Error(ctx, err) return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return ec.resolvers.Query().GetLocation(rctx, args["input"].(GetLocationInput)) + return ec.resolvers.Query().GetLocation(rctx, fc.Args["input"].(GetLocationInput)) }) if err != nil { ec.Error(ctx, err) @@ -9294,32 +10929,99 @@ func (ec *executionContext) _Query_getLocation(ctx context.Context, field graphq return ec.marshalNLocation2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐLocation(ctx, field.Selections, res) } -func (ec *executionContext) _Query_listLocations(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Query_getLocation(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Query", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Location_id(ctx, field) + case "uid": + return ec.fieldContext_Location_uid(ctx, field) + case "type": + return ec.fieldContext_Location_type(ctx, field) + case "name": + return ec.fieldContext_Location_name(ctx, field) + case "address": + return ec.fieldContext_Location_address(ctx, field) + case "city": + return ec.fieldContext_Location_city(ctx, field) + case "postalCode": + return ec.fieldContext_Location_postalCode(ctx, field) + case "country": + return ec.fieldContext_Location_country(ctx, field) + case "geom": + return ec.fieldContext_Location_geom(ctx, field) + case "relatedLocations": + return ec.fieldContext_Location_relatedLocations(ctx, field) + case "evses": + return ec.fieldContext_Location_evses(ctx, field) + case "availableEvses": + return ec.fieldContext_Location_availableEvses(ctx, field) + case "totalEvses": + return ec.fieldContext_Location_totalEvses(ctx, field) + case "isRemoteCapable": + return ec.fieldContext_Location_isRemoteCapable(ctx, field) + case "isRfidCapable": + return ec.fieldContext_Location_isRfidCapable(ctx, field) + case "directions": + return ec.fieldContext_Location_directions(ctx, field) + case "operator": + return ec.fieldContext_Location_operator(ctx, field) + case "suboperator": + return ec.fieldContext_Location_suboperator(ctx, field) + case "owner": + return ec.fieldContext_Location_owner(ctx, field) + case "facilities": + return ec.fieldContext_Location_facilities(ctx, field) + case "timeZone": + return ec.fieldContext_Location_timeZone(ctx, field) + case "openingTime": + return ec.fieldContext_Location_openingTime(ctx, field) + case "chargingWhenClosed": + return ec.fieldContext_Location_chargingWhenClosed(ctx, field) + case "images": + return ec.fieldContext_Location_images(ctx, field) + case "energyMix": + return ec.fieldContext_Location_energyMix(ctx, field) + case "lastUpdated": + return ec.fieldContext_Location_lastUpdated(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Location", field.Name) + }, } - + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Query_listLocations_args(ctx, rawArgs) - if err != nil { + if fc.Args, err = ec.field_Query_getLocation_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { ec.Error(ctx, err) + return + } + return fc, nil +} + +func (ec *executionContext) _Query_listLocations(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_listLocations(ctx, field) + if err != nil { return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return ec.resolvers.Query().ListLocations(rctx, args["input"].(ListLocationsInput)) + return ec.resolvers.Query().ListLocations(rctx, fc.Args["input"].(ListLocationsInput)) }) if err != nil { ec.Error(ctx, err) @@ -9336,32 +11038,61 @@ func (ec *executionContext) _Query_listLocations(ctx context.Context, field grap return ec.marshalNListLocation2ᚕgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐListLocationᚄ(ctx, field.Selections, res) } -func (ec *executionContext) _Query_getRate(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Query_listLocations(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Query", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "uid": + return ec.fieldContext_ListLocation_uid(ctx, field) + case "name": + return ec.fieldContext_ListLocation_name(ctx, field) + case "geom": + return ec.fieldContext_ListLocation_geom(ctx, field) + case "availableEvses": + return ec.fieldContext_ListLocation_availableEvses(ctx, field) + case "totalEvses": + return ec.fieldContext_ListLocation_totalEvses(ctx, field) + case "isRemoteCapable": + return ec.fieldContext_ListLocation_isRemoteCapable(ctx, field) + case "isRfidCapable": + return ec.fieldContext_ListLocation_isRfidCapable(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ListLocation", field.Name) + }, } - + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Query_getRate_args(ctx, rawArgs) - if err != nil { + if fc.Args, err = ec.field_Query_listLocations_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { ec.Error(ctx, err) + return + } + return fc, nil +} + +func (ec *executionContext) _Query_getRate(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_getRate(ctx, field) + if err != nil { return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return ec.resolvers.Query().GetRate(rctx, args["currency"].(string)) + return ec.resolvers.Query().GetRate(rctx, fc.Args["currency"].(string)) }) if err != nil { ec.Error(ctx, err) @@ -9375,32 +11106,53 @@ func (ec *executionContext) _Query_getRate(ctx context.Context, field graphql.Co return ec.marshalORate2ᚖgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐRate(ctx, field.Selections, res) } -func (ec *executionContext) _Query_getSession(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Query_getRate(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Query", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "rate": + return ec.fieldContext_Rate_rate(ctx, field) + case "rateMsat": + return ec.fieldContext_Rate_rateMsat(ctx, field) + case "lastUpdated": + return ec.fieldContext_Rate_lastUpdated(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Rate", field.Name) + }, } - + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Query_getSession_args(ctx, rawArgs) - if err != nil { + if fc.Args, err = ec.field_Query_getRate_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { ec.Error(ctx, err) + return + } + return fc, nil +} + +func (ec *executionContext) _Query_getSession(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_getSession(ctx, field) + if err != nil { return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return ec.resolvers.Query().GetSession(rctx, args["input"].(GetSessionInput)) + return ec.resolvers.Query().GetSession(rctx, fc.Args["input"].(GetSessionInput)) }) if err != nil { ec.Error(ctx, err) @@ -9417,32 +11169,75 @@ func (ec *executionContext) _Query_getSession(ctx context.Context, field graphql return ec.marshalNSession2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐSession(ctx, field.Selections, res) } -func (ec *executionContext) _Query_getSessionInvoice(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Query_getSession(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Query", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Session_id(ctx, field) + case "uid": + return ec.fieldContext_Session_uid(ctx, field) + case "authorizationId": + return ec.fieldContext_Session_authorizationId(ctx, field) + case "startDatetime": + return ec.fieldContext_Session_startDatetime(ctx, field) + case "endDatetime": + return ec.fieldContext_Session_endDatetime(ctx, field) + case "kwh": + return ec.fieldContext_Session_kwh(ctx, field) + case "authMethod": + return ec.fieldContext_Session_authMethod(ctx, field) + case "location": + return ec.fieldContext_Session_location(ctx, field) + case "evse": + return ec.fieldContext_Session_evse(ctx, field) + case "connector": + return ec.fieldContext_Session_connector(ctx, field) + case "meterId": + return ec.fieldContext_Session_meterId(ctx, field) + case "sessionInvoices": + return ec.fieldContext_Session_sessionInvoices(ctx, field) + case "status": + return ec.fieldContext_Session_status(ctx, field) + case "lastUpdated": + return ec.fieldContext_Session_lastUpdated(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Session", field.Name) + }, } - + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Query_getSessionInvoice_args(ctx, rawArgs) - if err != nil { + if fc.Args, err = ec.field_Query_getSession_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { ec.Error(ctx, err) + return + } + return fc, nil +} + +func (ec *executionContext) _Query_getSessionInvoice(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_getSessionInvoice(ctx, field) + if err != nil { return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return ec.resolvers.Query().GetSessionInvoice(rctx, args["id"].(int64)) + return ec.resolvers.Query().GetSessionInvoice(rctx, fc.Args["id"].(int64)) }) if err != nil { ec.Error(ctx, err) @@ -9456,32 +11251,81 @@ func (ec *executionContext) _Query_getSessionInvoice(ctx context.Context, field return ec.marshalOSessionInvoice2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐSessionInvoice(ctx, field.Selections, res) } -func (ec *executionContext) _Query_getTariff(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Query_getSessionInvoice(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Query", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_SessionInvoice_id(ctx, field) + case "currency": + return ec.fieldContext_SessionInvoice_currency(ctx, field) + case "currencyRate": + return ec.fieldContext_SessionInvoice_currencyRate(ctx, field) + case "currencyRateMsat": + return ec.fieldContext_SessionInvoice_currencyRateMsat(ctx, field) + case "priceFiat": + return ec.fieldContext_SessionInvoice_priceFiat(ctx, field) + case "priceMsat": + return ec.fieldContext_SessionInvoice_priceMsat(ctx, field) + case "commissionFiat": + return ec.fieldContext_SessionInvoice_commissionFiat(ctx, field) + case "commissionMsat": + return ec.fieldContext_SessionInvoice_commissionMsat(ctx, field) + case "taxFiat": + return ec.fieldContext_SessionInvoice_taxFiat(ctx, field) + case "taxMsat": + return ec.fieldContext_SessionInvoice_taxMsat(ctx, field) + case "totalFiat": + return ec.fieldContext_SessionInvoice_totalFiat(ctx, field) + case "totalMsat": + return ec.fieldContext_SessionInvoice_totalMsat(ctx, field) + case "paymentRequest": + return ec.fieldContext_SessionInvoice_paymentRequest(ctx, field) + case "signature": + return ec.fieldContext_SessionInvoice_signature(ctx, field) + case "isSettled": + return ec.fieldContext_SessionInvoice_isSettled(ctx, field) + case "isExpired": + return ec.fieldContext_SessionInvoice_isExpired(ctx, field) + case "lastUpdated": + return ec.fieldContext_SessionInvoice_lastUpdated(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type SessionInvoice", field.Name) + }, } - + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Query_getTariff_args(ctx, rawArgs) - if err != nil { + if fc.Args, err = ec.field_Query_getSessionInvoice_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { ec.Error(ctx, err) + return + } + return fc, nil +} + +func (ec *executionContext) _Query_getTariff(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_getTariff(ctx, field) + if err != nil { return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return ec.resolvers.Query().GetTariff(rctx, args["input"].(GetTariffInput)) + return ec.resolvers.Query().GetTariff(rctx, fc.Args["input"].(GetTariffInput)) }) if err != nil { ec.Error(ctx, err) @@ -9498,22 +11342,62 @@ func (ec *executionContext) _Query_getTariff(ctx context.Context, field graphql. return ec.marshalNTariff2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐTariff(ctx, field.Selections, res) } -func (ec *executionContext) _Query_getUser(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Query_getTariff(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Query", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Tariff_id(ctx, field) + case "uid": + return ec.fieldContext_Tariff_uid(ctx, field) + case "currency": + return ec.fieldContext_Tariff_currency(ctx, field) + case "currencyRate": + return ec.fieldContext_Tariff_currencyRate(ctx, field) + case "currencyRateMsat": + return ec.fieldContext_Tariff_currencyRateMsat(ctx, field) + case "commissionPercent": + return ec.fieldContext_Tariff_commissionPercent(ctx, field) + case "taxPercent": + return ec.fieldContext_Tariff_taxPercent(ctx, field) + case "elements": + return ec.fieldContext_Tariff_elements(ctx, field) + case "energyMix": + return ec.fieldContext_Tariff_energyMix(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Tariff", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Query_getTariff_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return } + return fc, nil +} +func (ec *executionContext) _Query_getUser(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query_getUser(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Query().GetUser(rctx) @@ -9533,32 +11417,44 @@ func (ec *executionContext) _Query_getUser(ctx context.Context, field graphql.Co return ec.marshalNUser2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐUser(ctx, field.Selections, res) } -func (ec *executionContext) _Query___type(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Query_getUser(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Query", Field: field, - Args: nil, IsMethod: true, - IsResolver: false, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_User_id(ctx, field) + case "pubkey": + return ec.fieldContext_User_pubkey(ctx, field) + case "deviceToken": + return ec.fieldContext_User_deviceToken(ctx, field) + case "referralCode": + return ec.fieldContext_User_referralCode(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type User", field.Name) + }, } + return fc, nil +} - ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field_Query___type_args(ctx, rawArgs) +func (ec *executionContext) _Query___type(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query___type(ctx, field) if err != nil { - ec.Error(ctx, err) return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return ec.introspectType(args["name"].(string)) + return ec.introspectType(fc.Args["name"].(string)) }) if err != nil { ec.Error(ctx, err) @@ -9572,22 +11468,64 @@ func (ec *executionContext) _Query___type(ctx context.Context, field graphql.Col return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) } -func (ec *executionContext) _Query___schema(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Query___type(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Query", Field: field, - Args: nil, IsMethod: true, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "kind": + return ec.fieldContext___Type_kind(ctx, field) + case "name": + return ec.fieldContext___Type_name(ctx, field) + case "description": + return ec.fieldContext___Type_description(ctx, field) + case "fields": + return ec.fieldContext___Type_fields(ctx, field) + case "interfaces": + return ec.fieldContext___Type_interfaces(ctx, field) + case "possibleTypes": + return ec.fieldContext___Type_possibleTypes(ctx, field) + case "enumValues": + return ec.fieldContext___Type_enumValues(ctx, field) + case "inputFields": + return ec.fieldContext___Type_inputFields(ctx, field) + case "ofType": + return ec.fieldContext___Type_ofType(ctx, field) + case "specifiedByURL": + return ec.fieldContext___Type_specifiedByURL(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field_Query___type_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return } + return fc, nil +} +func (ec *executionContext) _Query___schema(ctx context.Context, field graphql.CollectedField) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Query___schema(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.introspectSchema() @@ -9604,22 +11542,45 @@ func (ec *executionContext) _Query___schema(ctx context.Context, field graphql.C return ec.marshalO__Schema2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐSchema(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Query___schema(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Query", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "description": + return ec.fieldContext___Schema_description(ctx, field) + case "types": + return ec.fieldContext___Schema_types(ctx, field) + case "queryType": + return ec.fieldContext___Schema_queryType(ctx, field) + case "mutationType": + return ec.fieldContext___Schema_mutationType(ctx, field) + case "subscriptionType": + return ec.fieldContext___Schema_subscriptionType(ctx, field) + case "directives": + return ec.fieldContext___Schema_directives(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Schema", field.Name) + }, + } + return fc, nil +} + func (ec *executionContext) _Rate_rate(ctx context.Context, field graphql.CollectedField, obj *Rate) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Rate_rate(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Rate", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Rate, nil @@ -9639,22 +11600,31 @@ func (ec *executionContext) _Rate_rate(ctx context.Context, field graphql.Collec return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _Rate_rateMsat(ctx context.Context, field graphql.CollectedField, obj *Rate) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Rate_rate(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Rate", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Rate_rateMsat(ctx context.Context, field graphql.CollectedField, obj *Rate) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Rate_rateMsat(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.RateMsat, nil @@ -9674,22 +11644,31 @@ func (ec *executionContext) _Rate_rateMsat(ctx context.Context, field graphql.Co return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _Rate_lastUpdated(ctx context.Context, field graphql.CollectedField, obj *Rate) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Rate_rateMsat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Rate", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Rate_lastUpdated(ctx context.Context, field graphql.CollectedField, obj *Rate) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Rate_lastUpdated(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.LastUpdated, nil @@ -9709,22 +11688,31 @@ func (ec *executionContext) _Rate_lastUpdated(ctx context.Context, field graphql return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Rate_lastUpdated(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Rate", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _RegularHour_weekday(ctx context.Context, field graphql.CollectedField, obj *db.RegularHour) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_RegularHour_weekday(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "RegularHour", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.RegularHour().Weekday(rctx, obj) @@ -9744,22 +11732,31 @@ func (ec *executionContext) _RegularHour_weekday(ctx context.Context, field grap return ec.marshalNInt2int(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_RegularHour_weekday(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "RegularHour", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _RegularHour_periodBegin(ctx context.Context, field graphql.CollectedField, obj *db.RegularHour) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_RegularHour_periodBegin(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "RegularHour", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.PeriodBegin, nil @@ -9774,27 +11771,36 @@ func (ec *executionContext) _RegularHour_periodBegin(ctx context.Context, field } return graphql.Null } - res := resTmp.(string) - fc.Result = res - return ec.marshalNString2string(ctx, field.Selections, res) + res := resTmp.(string) + fc.Result = res + return ec.marshalNString2string(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_RegularHour_periodBegin(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "RegularHour", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil } func (ec *executionContext) _RegularHour_periodEnd(ctx context.Context, field graphql.CollectedField, obj *db.RegularHour) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_RegularHour_periodEnd(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "RegularHour", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.PeriodEnd, nil @@ -9814,22 +11820,31 @@ func (ec *executionContext) _RegularHour_periodEnd(ctx context.Context, field gr return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_RegularHour_periodEnd(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "RegularHour", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _ResultId_id(ctx context.Context, field graphql.CollectedField, obj *ResultID) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ResultId_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "ResultId", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.ID, nil @@ -9849,22 +11864,31 @@ func (ec *executionContext) _ResultId_id(ctx context.Context, field graphql.Coll return ec.marshalNID2int64(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_ResultId_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ResultId", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _ResultOk_ok(ctx context.Context, field graphql.CollectedField, obj *ResultOk) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_ResultOk_ok(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "ResultOk", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Ok, nil @@ -9884,22 +11908,31 @@ func (ec *executionContext) _ResultOk_ok(ctx context.Context, field graphql.Coll return ec.marshalNBoolean2bool(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_ResultOk_ok(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "ResultOk", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Session_id(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Session_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Session", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.ID, nil @@ -9919,22 +11952,31 @@ func (ec *executionContext) _Session_id(ctx context.Context, field graphql.Colle return ec.marshalNID2int64(ctx, field.Selections, res) } -func (ec *executionContext) _Session_uid(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Session_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Session", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Session_uid(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Session_uid(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Uid, nil @@ -9954,22 +11996,31 @@ func (ec *executionContext) _Session_uid(ctx context.Context, field graphql.Coll return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Session_uid(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Session", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Session_authorizationId(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Session_authorizationId(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Session", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Session().AuthorizationID(rctx, obj) @@ -9986,22 +12037,31 @@ func (ec *executionContext) _Session_authorizationId(ctx context.Context, field return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } -func (ec *executionContext) _Session_startDatetime(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Session_authorizationId(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Session", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Session_startDatetime(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Session_startDatetime(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Session().StartDatetime(rctx, obj) @@ -10021,22 +12081,31 @@ func (ec *executionContext) _Session_startDatetime(ctx context.Context, field gr return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _Session_endDatetime(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Session_startDatetime(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Session", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Session_endDatetime(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Session_endDatetime(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Session().EndDatetime(rctx, obj) @@ -10053,22 +12122,31 @@ func (ec *executionContext) _Session_endDatetime(ctx context.Context, field grap return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Session_endDatetime(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Session", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Session_kwh(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Session_kwh(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Session", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Kwh, nil @@ -10088,22 +12166,31 @@ func (ec *executionContext) _Session_kwh(ctx context.Context, field graphql.Coll return ec.marshalNFloat2float64(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Session_kwh(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Session", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Session_authMethod(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Session_authMethod(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Session", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Session().AuthMethod(rctx, obj) @@ -10123,22 +12210,31 @@ func (ec *executionContext) _Session_authMethod(ctx context.Context, field graph return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _Session_location(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Session_authMethod(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Session", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Session_location(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Session_location(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Session().Location(rctx, obj) @@ -10158,22 +12254,85 @@ func (ec *executionContext) _Session_location(ctx context.Context, field graphql return ec.marshalNLocation2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐLocation(ctx, field.Selections, res) } -func (ec *executionContext) _Session_evse(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Session_location(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Session", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Location_id(ctx, field) + case "uid": + return ec.fieldContext_Location_uid(ctx, field) + case "type": + return ec.fieldContext_Location_type(ctx, field) + case "name": + return ec.fieldContext_Location_name(ctx, field) + case "address": + return ec.fieldContext_Location_address(ctx, field) + case "city": + return ec.fieldContext_Location_city(ctx, field) + case "postalCode": + return ec.fieldContext_Location_postalCode(ctx, field) + case "country": + return ec.fieldContext_Location_country(ctx, field) + case "geom": + return ec.fieldContext_Location_geom(ctx, field) + case "relatedLocations": + return ec.fieldContext_Location_relatedLocations(ctx, field) + case "evses": + return ec.fieldContext_Location_evses(ctx, field) + case "availableEvses": + return ec.fieldContext_Location_availableEvses(ctx, field) + case "totalEvses": + return ec.fieldContext_Location_totalEvses(ctx, field) + case "isRemoteCapable": + return ec.fieldContext_Location_isRemoteCapable(ctx, field) + case "isRfidCapable": + return ec.fieldContext_Location_isRfidCapable(ctx, field) + case "directions": + return ec.fieldContext_Location_directions(ctx, field) + case "operator": + return ec.fieldContext_Location_operator(ctx, field) + case "suboperator": + return ec.fieldContext_Location_suboperator(ctx, field) + case "owner": + return ec.fieldContext_Location_owner(ctx, field) + case "facilities": + return ec.fieldContext_Location_facilities(ctx, field) + case "timeZone": + return ec.fieldContext_Location_timeZone(ctx, field) + case "openingTime": + return ec.fieldContext_Location_openingTime(ctx, field) + case "chargingWhenClosed": + return ec.fieldContext_Location_chargingWhenClosed(ctx, field) + case "images": + return ec.fieldContext_Location_images(ctx, field) + case "energyMix": + return ec.fieldContext_Location_energyMix(ctx, field) + case "lastUpdated": + return ec.fieldContext_Location_lastUpdated(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Location", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) _Session_evse(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Session_evse(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Session().Evse(rctx, obj) @@ -10193,22 +12352,65 @@ func (ec *executionContext) _Session_evse(ctx context.Context, field graphql.Col return ec.marshalNEvse2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐEvse(ctx, field.Selections, res) } -func (ec *executionContext) _Session_connector(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Session_evse(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Session", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Evse_id(ctx, field) + case "uid": + return ec.fieldContext_Evse_uid(ctx, field) + case "identifier": + return ec.fieldContext_Evse_identifier(ctx, field) + case "status": + return ec.fieldContext_Evse_status(ctx, field) + case "statusSchedule": + return ec.fieldContext_Evse_statusSchedule(ctx, field) + case "capabilities": + return ec.fieldContext_Evse_capabilities(ctx, field) + case "connectors": + return ec.fieldContext_Evse_connectors(ctx, field) + case "floorLevel": + return ec.fieldContext_Evse_floorLevel(ctx, field) + case "geom": + return ec.fieldContext_Evse_geom(ctx, field) + case "isRemoteCapable": + return ec.fieldContext_Evse_isRemoteCapable(ctx, field) + case "isRfidCapable": + return ec.fieldContext_Evse_isRfidCapable(ctx, field) + case "physicalReference": + return ec.fieldContext_Evse_physicalReference(ctx, field) + case "directions": + return ec.fieldContext_Evse_directions(ctx, field) + case "parkingRestrictions": + return ec.fieldContext_Evse_parkingRestrictions(ctx, field) + case "images": + return ec.fieldContext_Evse_images(ctx, field) + case "lastUpdated": + return ec.fieldContext_Evse_lastUpdated(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Evse", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) _Session_connector(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Session_connector(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Session().Connector(rctx, obj) @@ -10228,22 +12430,59 @@ func (ec *executionContext) _Session_connector(ctx context.Context, field graphq return ec.marshalNConnector2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐConnector(ctx, field.Selections, res) } -func (ec *executionContext) _Session_meterId(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Session_connector(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Session", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_Connector_id(ctx, field) + case "uid": + return ec.fieldContext_Connector_uid(ctx, field) + case "identifier": + return ec.fieldContext_Connector_identifier(ctx, field) + case "standard": + return ec.fieldContext_Connector_standard(ctx, field) + case "format": + return ec.fieldContext_Connector_format(ctx, field) + case "powerType": + return ec.fieldContext_Connector_powerType(ctx, field) + case "voltage": + return ec.fieldContext_Connector_voltage(ctx, field) + case "amperage": + return ec.fieldContext_Connector_amperage(ctx, field) + case "wattage": + return ec.fieldContext_Connector_wattage(ctx, field) + case "tariffId": + return ec.fieldContext_Connector_tariffId(ctx, field) + case "tariff": + return ec.fieldContext_Connector_tariff(ctx, field) + case "termsAndConditions": + return ec.fieldContext_Connector_termsAndConditions(ctx, field) + case "lastUpdated": + return ec.fieldContext_Connector_lastUpdated(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type Connector", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) _Session_meterId(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Session_meterId(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Session().MeterID(rctx, obj) @@ -10260,22 +12499,31 @@ func (ec *executionContext) _Session_meterId(ctx context.Context, field graphql. return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Session_meterId(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Session", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Session_sessionInvoices(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Session_sessionInvoices(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Session", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Session().SessionInvoices(rctx, obj) @@ -10295,22 +12543,67 @@ func (ec *executionContext) _Session_sessionInvoices(ctx context.Context, field return ec.marshalNSessionInvoice2ᚕgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐSessionInvoiceᚄ(ctx, field.Selections, res) } -func (ec *executionContext) _Session_status(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Session_sessionInvoices(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Session", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "id": + return ec.fieldContext_SessionInvoice_id(ctx, field) + case "currency": + return ec.fieldContext_SessionInvoice_currency(ctx, field) + case "currencyRate": + return ec.fieldContext_SessionInvoice_currencyRate(ctx, field) + case "currencyRateMsat": + return ec.fieldContext_SessionInvoice_currencyRateMsat(ctx, field) + case "priceFiat": + return ec.fieldContext_SessionInvoice_priceFiat(ctx, field) + case "priceMsat": + return ec.fieldContext_SessionInvoice_priceMsat(ctx, field) + case "commissionFiat": + return ec.fieldContext_SessionInvoice_commissionFiat(ctx, field) + case "commissionMsat": + return ec.fieldContext_SessionInvoice_commissionMsat(ctx, field) + case "taxFiat": + return ec.fieldContext_SessionInvoice_taxFiat(ctx, field) + case "taxMsat": + return ec.fieldContext_SessionInvoice_taxMsat(ctx, field) + case "totalFiat": + return ec.fieldContext_SessionInvoice_totalFiat(ctx, field) + case "totalMsat": + return ec.fieldContext_SessionInvoice_totalMsat(ctx, field) + case "paymentRequest": + return ec.fieldContext_SessionInvoice_paymentRequest(ctx, field) + case "signature": + return ec.fieldContext_SessionInvoice_signature(ctx, field) + case "isSettled": + return ec.fieldContext_SessionInvoice_isSettled(ctx, field) + case "isExpired": + return ec.fieldContext_SessionInvoice_isExpired(ctx, field) + case "lastUpdated": + return ec.fieldContext_SessionInvoice_lastUpdated(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type SessionInvoice", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) _Session_status(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Session_status(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Session().Status(rctx, obj) @@ -10330,22 +12623,31 @@ func (ec *executionContext) _Session_status(ctx context.Context, field graphql.C return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _Session_lastUpdated(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Session_status(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Session", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Session_lastUpdated(ctx context.Context, field graphql.CollectedField, obj *db.Session) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Session_lastUpdated(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Session().LastUpdated(rctx, obj) @@ -10365,22 +12667,31 @@ func (ec *executionContext) _Session_lastUpdated(ctx context.Context, field grap return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Session_lastUpdated(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Session", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _SessionInvoice_id(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SessionInvoice_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "SessionInvoice", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.ID, nil @@ -10400,22 +12711,31 @@ func (ec *executionContext) _SessionInvoice_id(ctx context.Context, field graphq return ec.marshalNID2int64(ctx, field.Selections, res) } -func (ec *executionContext) _SessionInvoice_currency(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_SessionInvoice_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "SessionInvoice", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _SessionInvoice_currency(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SessionInvoice_currency(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Currency, nil @@ -10435,22 +12755,31 @@ func (ec *executionContext) _SessionInvoice_currency(ctx context.Context, field return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _SessionInvoice_currencyRate(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_SessionInvoice_currency(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "SessionInvoice", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _SessionInvoice_currencyRate(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SessionInvoice_currencyRate(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.CurrencyRate, nil @@ -10470,22 +12799,31 @@ func (ec *executionContext) _SessionInvoice_currencyRate(ctx context.Context, fi return ec.marshalNInt2int64(ctx, field.Selections, res) } -func (ec *executionContext) _SessionInvoice_currencyRateMsat(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_SessionInvoice_currencyRate(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "SessionInvoice", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _SessionInvoice_currencyRateMsat(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SessionInvoice_currencyRateMsat(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.CurrencyRateMsat, nil @@ -10505,22 +12843,31 @@ func (ec *executionContext) _SessionInvoice_currencyRateMsat(ctx context.Context return ec.marshalNInt2int64(ctx, field.Selections, res) } -func (ec *executionContext) _SessionInvoice_priceFiat(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_SessionInvoice_currencyRateMsat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "SessionInvoice", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _SessionInvoice_priceFiat(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SessionInvoice_priceFiat(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.PriceFiat, nil @@ -10540,22 +12887,31 @@ func (ec *executionContext) _SessionInvoice_priceFiat(ctx context.Context, field return ec.marshalNFloat2float64(ctx, field.Selections, res) } -func (ec *executionContext) _SessionInvoice_priceMsat(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_SessionInvoice_priceFiat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "SessionInvoice", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _SessionInvoice_priceMsat(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SessionInvoice_priceMsat(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.PriceMsat, nil @@ -10575,22 +12931,31 @@ func (ec *executionContext) _SessionInvoice_priceMsat(ctx context.Context, field return ec.marshalNInt2int64(ctx, field.Selections, res) } -func (ec *executionContext) _SessionInvoice_commissionFiat(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_SessionInvoice_priceMsat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "SessionInvoice", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _SessionInvoice_commissionFiat(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SessionInvoice_commissionFiat(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.CommissionFiat, nil @@ -10610,22 +12975,31 @@ func (ec *executionContext) _SessionInvoice_commissionFiat(ctx context.Context, return ec.marshalNFloat2float64(ctx, field.Selections, res) } -func (ec *executionContext) _SessionInvoice_commissionMsat(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_SessionInvoice_commissionFiat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "SessionInvoice", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _SessionInvoice_commissionMsat(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SessionInvoice_commissionMsat(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.CommissionMsat, nil @@ -10645,22 +13019,31 @@ func (ec *executionContext) _SessionInvoice_commissionMsat(ctx context.Context, return ec.marshalNInt2int64(ctx, field.Selections, res) } -func (ec *executionContext) _SessionInvoice_taxFiat(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_SessionInvoice_commissionMsat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "SessionInvoice", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _SessionInvoice_taxFiat(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SessionInvoice_taxFiat(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.TaxFiat, nil @@ -10680,22 +13063,31 @@ func (ec *executionContext) _SessionInvoice_taxFiat(ctx context.Context, field g return ec.marshalNFloat2float64(ctx, field.Selections, res) } -func (ec *executionContext) _SessionInvoice_taxMsat(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_SessionInvoice_taxFiat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "SessionInvoice", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _SessionInvoice_taxMsat(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SessionInvoice_taxMsat(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.TaxMsat, nil @@ -10715,22 +13107,31 @@ func (ec *executionContext) _SessionInvoice_taxMsat(ctx context.Context, field g return ec.marshalNInt2int64(ctx, field.Selections, res) } -func (ec *executionContext) _SessionInvoice_totalFiat(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_SessionInvoice_taxMsat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "SessionInvoice", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _SessionInvoice_totalFiat(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SessionInvoice_totalFiat(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.TotalFiat, nil @@ -10745,27 +13146,36 @@ func (ec *executionContext) _SessionInvoice_totalFiat(ctx context.Context, field } return graphql.Null } - res := resTmp.(float64) - fc.Result = res - return ec.marshalNFloat2float64(ctx, field.Selections, res) + res := resTmp.(float64) + fc.Result = res + return ec.marshalNFloat2float64(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext_SessionInvoice_totalFiat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "SessionInvoice", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, + } + return fc, nil } func (ec *executionContext) _SessionInvoice_totalMsat(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SessionInvoice_totalMsat(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "SessionInvoice", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.TotalMsat, nil @@ -10785,22 +13195,31 @@ func (ec *executionContext) _SessionInvoice_totalMsat(ctx context.Context, field return ec.marshalNInt2int64(ctx, field.Selections, res) } -func (ec *executionContext) _SessionInvoice_paymentRequest(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_SessionInvoice_totalMsat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "SessionInvoice", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _SessionInvoice_paymentRequest(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SessionInvoice_paymentRequest(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.PaymentRequest, nil @@ -10820,22 +13239,31 @@ func (ec *executionContext) _SessionInvoice_paymentRequest(ctx context.Context, return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_SessionInvoice_paymentRequest(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "SessionInvoice", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _SessionInvoice_signature(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SessionInvoice_signature(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "SessionInvoice", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.SessionInvoice().Signature(rctx, obj) @@ -10855,22 +13283,31 @@ func (ec *executionContext) _SessionInvoice_signature(ctx context.Context, field return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_SessionInvoice_signature(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "SessionInvoice", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _SessionInvoice_isSettled(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SessionInvoice_isSettled(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "SessionInvoice", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.IsSettled, nil @@ -10890,22 +13327,31 @@ func (ec *executionContext) _SessionInvoice_isSettled(ctx context.Context, field return ec.marshalNBoolean2bool(ctx, field.Selections, res) } -func (ec *executionContext) _SessionInvoice_isExpired(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_SessionInvoice_isSettled(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "SessionInvoice", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _SessionInvoice_isExpired(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SessionInvoice_isExpired(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.IsExpired, nil @@ -10925,22 +13371,31 @@ func (ec *executionContext) _SessionInvoice_isExpired(ctx context.Context, field return ec.marshalNBoolean2bool(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_SessionInvoice_isExpired(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "SessionInvoice", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _SessionInvoice_lastUpdated(ctx context.Context, field graphql.CollectedField, obj *db.SessionInvoice) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_SessionInvoice_lastUpdated(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "SessionInvoice", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.SessionInvoice().LastUpdated(rctx, obj) @@ -10960,22 +13415,31 @@ func (ec *executionContext) _SessionInvoice_lastUpdated(ctx context.Context, fie return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_SessionInvoice_lastUpdated(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "SessionInvoice", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _StartSession_id(ctx context.Context, field graphql.CollectedField, obj *StartSession) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_StartSession_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "StartSession", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.ID, nil @@ -10995,22 +13459,31 @@ func (ec *executionContext) _StartSession_id(ctx context.Context, field graphql. return ec.marshalNID2int64(ctx, field.Selections, res) } -func (ec *executionContext) _StartSession_status(ctx context.Context, field graphql.CollectedField, obj *StartSession) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_StartSession_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "StartSession", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _StartSession_status(ctx context.Context, field graphql.CollectedField, obj *StartSession) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_StartSession_status(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Status, nil @@ -11030,22 +13503,31 @@ func (ec *executionContext) _StartSession_status(ctx context.Context, field grap return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _StartSession_authorizationId(ctx context.Context, field graphql.CollectedField, obj *StartSession) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_StartSession_status(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "StartSession", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _StartSession_authorizationId(ctx context.Context, field graphql.CollectedField, obj *StartSession) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_StartSession_authorizationId(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.AuthorizationID, nil @@ -11065,22 +13547,31 @@ func (ec *executionContext) _StartSession_authorizationId(ctx context.Context, f return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _StartSession_verificationKey(ctx context.Context, field graphql.CollectedField, obj *StartSession) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_StartSession_authorizationId(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "StartSession", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _StartSession_verificationKey(ctx context.Context, field graphql.CollectedField, obj *StartSession) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_StartSession_verificationKey(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.VerificationKey, nil @@ -11100,22 +13591,31 @@ func (ec *executionContext) _StartSession_verificationKey(ctx context.Context, f return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _StartSession_locationUid(ctx context.Context, field graphql.CollectedField, obj *StartSession) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_StartSession_verificationKey(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "StartSession", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _StartSession_locationUid(ctx context.Context, field graphql.CollectedField, obj *StartSession) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_StartSession_locationUid(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.LocationUID, nil @@ -11135,22 +13635,31 @@ func (ec *executionContext) _StartSession_locationUid(ctx context.Context, field return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _StartSession_evseUid(ctx context.Context, field graphql.CollectedField, obj *StartSession) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_StartSession_locationUid(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "StartSession", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _StartSession_evseUid(ctx context.Context, field graphql.CollectedField, obj *StartSession) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_StartSession_evseUid(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.EvseUID, nil @@ -11167,22 +13676,31 @@ func (ec *executionContext) _StartSession_evseUid(ctx context.Context, field gra return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_StartSession_evseUid(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "StartSession", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _StatusSchedule_periodBegin(ctx context.Context, field graphql.CollectedField, obj *db.StatusSchedule) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_StatusSchedule_periodBegin(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "StatusSchedule", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.StatusSchedule().PeriodBegin(rctx, obj) @@ -11202,22 +13720,31 @@ func (ec *executionContext) _StatusSchedule_periodBegin(ctx context.Context, fie return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _StatusSchedule_periodEnd(ctx context.Context, field graphql.CollectedField, obj *db.StatusSchedule) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_StatusSchedule_periodBegin(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "StatusSchedule", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _StatusSchedule_periodEnd(ctx context.Context, field graphql.CollectedField, obj *db.StatusSchedule) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_StatusSchedule_periodEnd(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.StatusSchedule().PeriodEnd(rctx, obj) @@ -11234,22 +13761,31 @@ func (ec *executionContext) _StatusSchedule_periodEnd(ctx context.Context, field return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_StatusSchedule_periodEnd(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "StatusSchedule", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _StatusSchedule_status(ctx context.Context, field graphql.CollectedField, obj *db.StatusSchedule) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_StatusSchedule_status(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "StatusSchedule", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.StatusSchedule().Status(rctx, obj) @@ -11269,22 +13805,31 @@ func (ec *executionContext) _StatusSchedule_status(ctx context.Context, field gr return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_StatusSchedule_status(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "StatusSchedule", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _StopSession_id(ctx context.Context, field graphql.CollectedField, obj *StopSession) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_StopSession_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "StopSession", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.ID, nil @@ -11304,22 +13849,31 @@ func (ec *executionContext) _StopSession_id(ctx context.Context, field graphql.C return ec.marshalNID2int64(ctx, field.Selections, res) } -func (ec *executionContext) _StopSession_status(ctx context.Context, field graphql.CollectedField, obj *StopSession) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_StopSession_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "StopSession", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _StopSession_status(ctx context.Context, field graphql.CollectedField, obj *StopSession) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_StopSession_status(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Status, nil @@ -11339,22 +13893,31 @@ func (ec *executionContext) _StopSession_status(ctx context.Context, field graph return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _StopSession_sessionUid(ctx context.Context, field graphql.CollectedField, obj *StopSession) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_StopSession_status(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "StopSession", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _StopSession_sessionUid(ctx context.Context, field graphql.CollectedField, obj *StopSession) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_StopSession_sessionUid(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.SessionUID, nil @@ -11374,22 +13937,31 @@ func (ec *executionContext) _StopSession_sessionUid(ctx context.Context, field g return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_StopSession_sessionUid(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "StopSession", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Tariff_id(ctx context.Context, field graphql.CollectedField, obj *db.Tariff) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Tariff_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Tariff", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.ID, nil @@ -11409,22 +13981,31 @@ func (ec *executionContext) _Tariff_id(ctx context.Context, field graphql.Collec return ec.marshalNID2int64(ctx, field.Selections, res) } -func (ec *executionContext) _Tariff_uid(ctx context.Context, field graphql.CollectedField, obj *db.Tariff) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Tariff_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Tariff", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Tariff_uid(ctx context.Context, field graphql.CollectedField, obj *db.Tariff) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Tariff_uid(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Uid, nil @@ -11444,22 +14025,31 @@ func (ec *executionContext) _Tariff_uid(ctx context.Context, field graphql.Colle return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _Tariff_currency(ctx context.Context, field graphql.CollectedField, obj *db.Tariff) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Tariff_uid(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Tariff", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Tariff_currency(ctx context.Context, field graphql.CollectedField, obj *db.Tariff) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Tariff_currency(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Currency, nil @@ -11479,22 +14069,31 @@ func (ec *executionContext) _Tariff_currency(ctx context.Context, field graphql. return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Tariff_currency(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Tariff", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _Tariff_currencyRate(ctx context.Context, field graphql.CollectedField, obj *db.Tariff) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Tariff_currencyRate(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "Tariff", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Tariff().CurrencyRate(rctx, obj) @@ -11514,22 +14113,31 @@ func (ec *executionContext) _Tariff_currencyRate(ctx context.Context, field grap return ec.marshalNInt2int(ctx, field.Selections, res) } -func (ec *executionContext) _Tariff_currencyRateMsat(ctx context.Context, field graphql.CollectedField, obj *db.Tariff) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Tariff_currencyRate(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Tariff", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Tariff_currencyRateMsat(ctx context.Context, field graphql.CollectedField, obj *db.Tariff) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Tariff_currencyRateMsat(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Tariff().CurrencyRateMsat(rctx, obj) @@ -11549,22 +14157,31 @@ func (ec *executionContext) _Tariff_currencyRateMsat(ctx context.Context, field return ec.marshalNInt2int(ctx, field.Selections, res) } -func (ec *executionContext) _Tariff_commissionPercent(ctx context.Context, field graphql.CollectedField, obj *db.Tariff) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Tariff_currencyRateMsat(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Tariff", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Int does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Tariff_commissionPercent(ctx context.Context, field graphql.CollectedField, obj *db.Tariff) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Tariff_commissionPercent(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Tariff().CommissionPercent(rctx, obj) @@ -11584,22 +14201,31 @@ func (ec *executionContext) _Tariff_commissionPercent(ctx context.Context, field return ec.marshalNFloat2float64(ctx, field.Selections, res) } -func (ec *executionContext) _Tariff_taxPercent(ctx context.Context, field graphql.CollectedField, obj *db.Tariff) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Tariff_commissionPercent(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Tariff", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Tariff_taxPercent(ctx context.Context, field graphql.CollectedField, obj *db.Tariff) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Tariff_taxPercent(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Tariff().TaxPercent(rctx, obj) @@ -11616,22 +14242,31 @@ func (ec *executionContext) _Tariff_taxPercent(ctx context.Context, field graphq return ec.marshalOFloat2ᚖfloat64(ctx, field.Selections, res) } -func (ec *executionContext) _Tariff_elements(ctx context.Context, field graphql.CollectedField, obj *db.Tariff) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Tariff_taxPercent(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Tariff", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Float does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _Tariff_elements(ctx context.Context, field graphql.CollectedField, obj *db.Tariff) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Tariff_elements(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Tariff().Elements(rctx, obj) @@ -11651,22 +14286,37 @@ func (ec *executionContext) _Tariff_elements(ctx context.Context, field graphql. return ec.marshalNTariffElement2ᚕgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐTariffElementᚄ(ctx, field.Selections, res) } -func (ec *executionContext) _Tariff_energyMix(ctx context.Context, field graphql.CollectedField, obj *db.Tariff) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_Tariff_elements(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "Tariff", Field: field, - Args: nil, IsMethod: true, IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "priceComponents": + return ec.fieldContext_TariffElement_priceComponents(ctx, field) + case "restrictions": + return ec.fieldContext_TariffElement_restrictions(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type TariffElement", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) _Tariff_energyMix(ctx context.Context, field graphql.CollectedField, obj *db.Tariff) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_Tariff_energyMix(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.Tariff().EnergyMix(rctx, obj) @@ -11683,22 +14333,43 @@ func (ec *executionContext) _Tariff_energyMix(ctx context.Context, field graphql return ec.marshalOEnergyMix2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐEnergyMix(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_Tariff_energyMix(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "Tariff", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "isGreenEnergy": + return ec.fieldContext_EnergyMix_isGreenEnergy(ctx, field) + case "energySources": + return ec.fieldContext_EnergyMix_energySources(ctx, field) + case "environmentalImpact": + return ec.fieldContext_EnergyMix_environmentalImpact(ctx, field) + case "supplierName": + return ec.fieldContext_EnergyMix_supplierName(ctx, field) + case "energyProductName": + return ec.fieldContext_EnergyMix_energyProductName(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type EnergyMix", field.Name) + }, + } + return fc, nil +} + func (ec *executionContext) _TariffElement_priceComponents(ctx context.Context, field graphql.CollectedField, obj *TariffElement) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_TariffElement_priceComponents(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "TariffElement", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.PriceComponents, nil @@ -11715,22 +14386,45 @@ func (ec *executionContext) _TariffElement_priceComponents(ctx context.Context, return ec.marshalOPriceComponent2ᚕgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐPriceComponentᚄ(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_TariffElement_priceComponents(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "TariffElement", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "type": + return ec.fieldContext_PriceComponent_type(ctx, field) + case "price": + return ec.fieldContext_PriceComponent_price(ctx, field) + case "priceMsat": + return ec.fieldContext_PriceComponent_priceMsat(ctx, field) + case "commissionMsat": + return ec.fieldContext_PriceComponent_commissionMsat(ctx, field) + case "taxMsat": + return ec.fieldContext_PriceComponent_taxMsat(ctx, field) + case "stepSize": + return ec.fieldContext_PriceComponent_stepSize(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type PriceComponent", field.Name) + }, + } + return fc, nil +} + func (ec *executionContext) _TariffElement_restrictions(ctx context.Context, field graphql.CollectedField, obj *TariffElement) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_TariffElement_restrictions(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "TariffElement", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Restrictions, nil @@ -11747,22 +14441,55 @@ func (ec *executionContext) _TariffElement_restrictions(ctx context.Context, fie return ec.marshalOElementRestriction2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐElementRestriction(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_TariffElement_restrictions(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "TariffElement", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "startTime": + return ec.fieldContext_ElementRestriction_startTime(ctx, field) + case "endTime": + return ec.fieldContext_ElementRestriction_endTime(ctx, field) + case "startDate": + return ec.fieldContext_ElementRestriction_startDate(ctx, field) + case "endDate": + return ec.fieldContext_ElementRestriction_endDate(ctx, field) + case "minKwh": + return ec.fieldContext_ElementRestriction_minKwh(ctx, field) + case "maxKwh": + return ec.fieldContext_ElementRestriction_maxKwh(ctx, field) + case "minPower": + return ec.fieldContext_ElementRestriction_minPower(ctx, field) + case "maxPower": + return ec.fieldContext_ElementRestriction_maxPower(ctx, field) + case "minDuration": + return ec.fieldContext_ElementRestriction_minDuration(ctx, field) + case "maxDuration": + return ec.fieldContext_ElementRestriction_maxDuration(ctx, field) + case "dayOfWeek": + return ec.fieldContext_ElementRestriction_dayOfWeek(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type ElementRestriction", field.Name) + }, + } + return fc, nil +} + func (ec *executionContext) _TextDescription_text(ctx context.Context, field graphql.CollectedField, obj *TextDescription) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_TextDescription_text(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "TextDescription", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Text, nil @@ -11782,22 +14509,31 @@ func (ec *executionContext) _TextDescription_text(ctx context.Context, field gra return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _TextDescription_description(ctx context.Context, field graphql.CollectedField, obj *TextDescription) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_TextDescription_text(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "TextDescription", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _TextDescription_description(ctx context.Context, field graphql.CollectedField, obj *TextDescription) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_TextDescription_description(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Description, nil @@ -11817,22 +14553,31 @@ func (ec *executionContext) _TextDescription_description(ctx context.Context, fi return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_TextDescription_description(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "TextDescription", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _User_id(ctx context.Context, field graphql.CollectedField, obj *db.User) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_User_id(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "User", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.ID, nil @@ -11852,22 +14597,31 @@ func (ec *executionContext) _User_id(ctx context.Context, field graphql.Collecte return ec.marshalNID2int64(ctx, field.Selections, res) } -func (ec *executionContext) _User_pubkey(ctx context.Context, field graphql.CollectedField, obj *db.User) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_User_id(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "User", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type ID does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _User_pubkey(ctx context.Context, field graphql.CollectedField, obj *db.User) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_User_pubkey(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Pubkey, nil @@ -11887,22 +14641,31 @@ func (ec *executionContext) _User_pubkey(ctx context.Context, field graphql.Coll return ec.marshalNString2string(ctx, field.Selections, res) } -func (ec *executionContext) _User_deviceToken(ctx context.Context, field graphql.CollectedField, obj *db.User) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext_User_pubkey(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "User", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) _User_deviceToken(ctx context.Context, field graphql.CollectedField, obj *db.User) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_User_deviceToken(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.DeviceToken, nil @@ -11922,22 +14685,31 @@ func (ec *executionContext) _User_deviceToken(ctx context.Context, field graphql return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_User_deviceToken(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "User", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _User_referralCode(ctx context.Context, field graphql.CollectedField, obj *db.User) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_User_referralCode(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "User", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: true, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return ec.resolvers.User().ReferralCode(rctx, obj) @@ -11954,22 +14726,31 @@ func (ec *executionContext) _User_referralCode(ctx context.Context, field graphq return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_User_referralCode(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "User", + Field: field, + IsMethod: true, + IsResolver: true, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) _VerifyAuthentication_verified(ctx context.Context, field graphql.CollectedField, obj *VerifyAuthentication) (ret graphql.Marshaler) { + fc, err := ec.fieldContext_VerifyAuthentication_verified(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "VerifyAuthentication", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Verified, nil @@ -11989,22 +14770,31 @@ func (ec *executionContext) _VerifyAuthentication_verified(ctx context.Context, return ec.marshalNBoolean2bool(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext_VerifyAuthentication_verified(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "VerifyAuthentication", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) ___Directive_name(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Directive_name(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "__Directive", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Name, nil @@ -12024,22 +14814,31 @@ func (ec *executionContext) ___Directive_name(ctx context.Context, field graphql return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext___Directive_name(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Directive", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) ___Directive_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Directive_description(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "__Directive", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Description(), nil @@ -12056,22 +14855,31 @@ func (ec *executionContext) ___Directive_description(ctx context.Context, field return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext___Directive_description(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Directive", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) ___Directive_locations(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Directive_locations(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "__Directive", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Locations, nil @@ -12091,22 +14899,31 @@ func (ec *executionContext) ___Directive_locations(ctx context.Context, field gr return ec.marshalN__DirectiveLocation2ᚕstringᚄ(ctx, field.Selections, res) } -func (ec *executionContext) ___Directive_args(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext___Directive_locations(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "__Directive", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type __DirectiveLocation does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) ___Directive_args(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Directive_args(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Args, nil @@ -12126,22 +14943,41 @@ func (ec *executionContext) ___Directive_args(ctx context.Context, field graphql return ec.marshalN__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx, field.Selections, res) } -func (ec *executionContext) ___Directive_isRepeatable(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext___Directive_args(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "__Directive", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "name": + return ec.fieldContext___InputValue_name(ctx, field) + case "description": + return ec.fieldContext___InputValue_description(ctx, field) + case "type": + return ec.fieldContext___InputValue_type(ctx, field) + case "defaultValue": + return ec.fieldContext___InputValue_defaultValue(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __InputValue", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) ___Directive_isRepeatable(ctx context.Context, field graphql.CollectedField, obj *introspection.Directive) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Directive_isRepeatable(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.IsRepeatable, nil @@ -12161,22 +14997,31 @@ func (ec *executionContext) ___Directive_isRepeatable(ctx context.Context, field return ec.marshalNBoolean2bool(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext___Directive_isRepeatable(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Directive", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) ___EnumValue_name(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___EnumValue_name(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "__EnumValue", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Name, nil @@ -12196,22 +15041,31 @@ func (ec *executionContext) ___EnumValue_name(ctx context.Context, field graphql return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext___EnumValue_name(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__EnumValue", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) ___EnumValue_description(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___EnumValue_description(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "__EnumValue", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Description(), nil @@ -12228,22 +15082,31 @@ func (ec *executionContext) ___EnumValue_description(ctx context.Context, field return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } -func (ec *executionContext) ___EnumValue_isDeprecated(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext___EnumValue_description(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "__EnumValue", Field: field, - Args: nil, IsMethod: true, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) ___EnumValue_isDeprecated(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___EnumValue_isDeprecated(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.IsDeprecated(), nil @@ -12263,22 +15126,31 @@ func (ec *executionContext) ___EnumValue_isDeprecated(ctx context.Context, field return ec.marshalNBoolean2bool(ctx, field.Selections, res) } -func (ec *executionContext) ___EnumValue_deprecationReason(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext___EnumValue_isDeprecated(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "__EnumValue", Field: field, - Args: nil, IsMethod: true, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) ___EnumValue_deprecationReason(ctx context.Context, field graphql.CollectedField, obj *introspection.EnumValue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___EnumValue_deprecationReason(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.DeprecationReason(), nil @@ -12295,22 +15167,31 @@ func (ec *executionContext) ___EnumValue_deprecationReason(ctx context.Context, return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext___EnumValue_deprecationReason(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__EnumValue", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) ___Field_name(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Field_name(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "__Field", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Name, nil @@ -12330,22 +15211,31 @@ func (ec *executionContext) ___Field_name(ctx context.Context, field graphql.Col return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext___Field_name(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Field", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) ___Field_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Field_description(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "__Field", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Description(), nil @@ -12362,22 +15252,31 @@ func (ec *executionContext) ___Field_description(ctx context.Context, field grap return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext___Field_description(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Field", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) ___Field_args(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Field_args(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "__Field", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Args, nil @@ -12397,22 +15296,41 @@ func (ec *executionContext) ___Field_args(ctx context.Context, field graphql.Col return ec.marshalN__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx, field.Selections, res) } -func (ec *executionContext) ___Field_type(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext___Field_args(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "__Field", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "name": + return ec.fieldContext___InputValue_name(ctx, field) + case "description": + return ec.fieldContext___InputValue_description(ctx, field) + case "type": + return ec.fieldContext___InputValue_type(ctx, field) + case "defaultValue": + return ec.fieldContext___InputValue_defaultValue(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __InputValue", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) ___Field_type(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Field_type(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Type, nil @@ -12432,22 +15350,53 @@ func (ec *executionContext) ___Field_type(ctx context.Context, field graphql.Col return ec.marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext___Field_type(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Field", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "kind": + return ec.fieldContext___Type_kind(ctx, field) + case "name": + return ec.fieldContext___Type_name(ctx, field) + case "description": + return ec.fieldContext___Type_description(ctx, field) + case "fields": + return ec.fieldContext___Type_fields(ctx, field) + case "interfaces": + return ec.fieldContext___Type_interfaces(ctx, field) + case "possibleTypes": + return ec.fieldContext___Type_possibleTypes(ctx, field) + case "enumValues": + return ec.fieldContext___Type_enumValues(ctx, field) + case "inputFields": + return ec.fieldContext___Type_inputFields(ctx, field) + case "ofType": + return ec.fieldContext___Type_ofType(ctx, field) + case "specifiedByURL": + return ec.fieldContext___Type_specifiedByURL(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) + }, + } + return fc, nil +} + func (ec *executionContext) ___Field_isDeprecated(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Field_isDeprecated(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "__Field", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.IsDeprecated(), nil @@ -12467,22 +15416,31 @@ func (ec *executionContext) ___Field_isDeprecated(ctx context.Context, field gra return ec.marshalNBoolean2bool(ctx, field.Selections, res) } -func (ec *executionContext) ___Field_deprecationReason(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext___Field_isDeprecated(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "__Field", Field: field, - Args: nil, IsMethod: true, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type Boolean does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) ___Field_deprecationReason(ctx context.Context, field graphql.CollectedField, obj *introspection.Field) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Field_deprecationReason(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.DeprecationReason(), nil @@ -12499,22 +15457,31 @@ func (ec *executionContext) ___Field_deprecationReason(ctx context.Context, fiel return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext___Field_deprecationReason(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Field", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) ___InputValue_name(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___InputValue_name(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "__InputValue", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Name, nil @@ -12534,22 +15501,31 @@ func (ec *executionContext) ___InputValue_name(ctx context.Context, field graphq return ec.marshalNString2string(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext___InputValue_name(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__InputValue", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) ___InputValue_description(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___InputValue_description(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "__InputValue", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Description(), nil @@ -12566,22 +15542,31 @@ func (ec *executionContext) ___InputValue_description(ctx context.Context, field return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext___InputValue_description(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__InputValue", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil +} + func (ec *executionContext) ___InputValue_type(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___InputValue_type(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "__InputValue", - Field: field, - Args: nil, - IsMethod: false, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Type, nil @@ -12601,25 +15586,97 @@ func (ec *executionContext) ___InputValue_type(ctx context.Context, field graphq return ec.marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext___InputValue_type(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__InputValue", + Field: field, + IsMethod: false, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "kind": + return ec.fieldContext___Type_kind(ctx, field) + case "name": + return ec.fieldContext___Type_name(ctx, field) + case "description": + return ec.fieldContext___Type_description(ctx, field) + case "fields": + return ec.fieldContext___Type_fields(ctx, field) + case "interfaces": + return ec.fieldContext___Type_interfaces(ctx, field) + case "possibleTypes": + return ec.fieldContext___Type_possibleTypes(ctx, field) + case "enumValues": + return ec.fieldContext___Type_enumValues(ctx, field) + case "inputFields": + return ec.fieldContext___Type_inputFields(ctx, field) + case "ofType": + return ec.fieldContext___Type_ofType(ctx, field) + case "specifiedByURL": + return ec.fieldContext___Type_specifiedByURL(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) + }, + } + return fc, nil +} + func (ec *executionContext) ___InputValue_defaultValue(ctx context.Context, field graphql.CollectedField, obj *introspection.InputValue) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___InputValue_defaultValue(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.DefaultValue, nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___InputValue_defaultValue(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "__InputValue", Field: field, - Args: nil, IsMethod: false, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) ___Schema_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Schema_description(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.DefaultValue, nil + return obj.Description(), nil }) if err != nil { ec.Error(ctx, err) @@ -12628,27 +15685,36 @@ func (ec *executionContext) ___InputValue_defaultValue(ctx context.Context, fiel if resTmp == nil { return graphql.Null } - res := resTmp.(*string) - fc.Result = res - return ec.marshalOString2ᚖstring(ctx, field.Selections, res) + res := resTmp.(*string) + fc.Result = res + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Schema_description(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Schema", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil } func (ec *executionContext) ___Schema_types(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Schema_types(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "__Schema", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Types(), nil @@ -12668,22 +15734,53 @@ func (ec *executionContext) ___Schema_types(ctx context.Context, field graphql.C return ec.marshalN__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx, field.Selections, res) } -func (ec *executionContext) ___Schema_queryType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext___Schema_types(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "__Schema", Field: field, - Args: nil, IsMethod: true, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "kind": + return ec.fieldContext___Type_kind(ctx, field) + case "name": + return ec.fieldContext___Type_name(ctx, field) + case "description": + return ec.fieldContext___Type_description(ctx, field) + case "fields": + return ec.fieldContext___Type_fields(ctx, field) + case "interfaces": + return ec.fieldContext___Type_interfaces(ctx, field) + case "possibleTypes": + return ec.fieldContext___Type_possibleTypes(ctx, field) + case "enumValues": + return ec.fieldContext___Type_enumValues(ctx, field) + case "inputFields": + return ec.fieldContext___Type_inputFields(ctx, field) + case "ofType": + return ec.fieldContext___Type_ofType(ctx, field) + case "specifiedByURL": + return ec.fieldContext___Type_specifiedByURL(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) ___Schema_queryType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Schema_queryType(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.QueryType(), nil @@ -12703,22 +15800,53 @@ func (ec *executionContext) ___Schema_queryType(ctx context.Context, field graph return ec.marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) } -func (ec *executionContext) ___Schema_mutationType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext___Schema_queryType(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "__Schema", Field: field, - Args: nil, IsMethod: true, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "kind": + return ec.fieldContext___Type_kind(ctx, field) + case "name": + return ec.fieldContext___Type_name(ctx, field) + case "description": + return ec.fieldContext___Type_description(ctx, field) + case "fields": + return ec.fieldContext___Type_fields(ctx, field) + case "interfaces": + return ec.fieldContext___Type_interfaces(ctx, field) + case "possibleTypes": + return ec.fieldContext___Type_possibleTypes(ctx, field) + case "enumValues": + return ec.fieldContext___Type_enumValues(ctx, field) + case "inputFields": + return ec.fieldContext___Type_inputFields(ctx, field) + case "ofType": + return ec.fieldContext___Type_ofType(ctx, field) + case "specifiedByURL": + return ec.fieldContext___Type_specifiedByURL(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) ___Schema_mutationType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Schema_mutationType(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.MutationType(), nil @@ -12735,22 +15863,53 @@ func (ec *executionContext) ___Schema_mutationType(ctx context.Context, field gr return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) } -func (ec *executionContext) ___Schema_subscriptionType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext___Schema_mutationType(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "__Schema", Field: field, - Args: nil, IsMethod: true, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "kind": + return ec.fieldContext___Type_kind(ctx, field) + case "name": + return ec.fieldContext___Type_name(ctx, field) + case "description": + return ec.fieldContext___Type_description(ctx, field) + case "fields": + return ec.fieldContext___Type_fields(ctx, field) + case "interfaces": + return ec.fieldContext___Type_interfaces(ctx, field) + case "possibleTypes": + return ec.fieldContext___Type_possibleTypes(ctx, field) + case "enumValues": + return ec.fieldContext___Type_enumValues(ctx, field) + case "inputFields": + return ec.fieldContext___Type_inputFields(ctx, field) + case "ofType": + return ec.fieldContext___Type_ofType(ctx, field) + case "specifiedByURL": + return ec.fieldContext___Type_specifiedByURL(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) ___Schema_subscriptionType(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Schema_subscriptionType(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.SubscriptionType(), nil @@ -12767,22 +15926,53 @@ func (ec *executionContext) ___Schema_subscriptionType(ctx context.Context, fiel return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) } -func (ec *executionContext) ___Schema_directives(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext___Schema_subscriptionType(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "__Schema", Field: field, - Args: nil, IsMethod: true, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "kind": + return ec.fieldContext___Type_kind(ctx, field) + case "name": + return ec.fieldContext___Type_name(ctx, field) + case "description": + return ec.fieldContext___Type_description(ctx, field) + case "fields": + return ec.fieldContext___Type_fields(ctx, field) + case "interfaces": + return ec.fieldContext___Type_interfaces(ctx, field) + case "possibleTypes": + return ec.fieldContext___Type_possibleTypes(ctx, field) + case "enumValues": + return ec.fieldContext___Type_enumValues(ctx, field) + case "inputFields": + return ec.fieldContext___Type_inputFields(ctx, field) + case "ofType": + return ec.fieldContext___Type_ofType(ctx, field) + case "specifiedByURL": + return ec.fieldContext___Type_specifiedByURL(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) ___Schema_directives(ctx context.Context, field graphql.CollectedField, obj *introspection.Schema) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Schema_directives(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Directives(), nil @@ -12802,22 +15992,43 @@ func (ec *executionContext) ___Schema_directives(ctx context.Context, field grap return ec.marshalN__Directive2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐDirectiveᚄ(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext___Schema_directives(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Schema", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "name": + return ec.fieldContext___Directive_name(ctx, field) + case "description": + return ec.fieldContext___Directive_description(ctx, field) + case "locations": + return ec.fieldContext___Directive_locations(ctx, field) + case "args": + return ec.fieldContext___Directive_args(ctx, field) + case "isRepeatable": + return ec.fieldContext___Directive_isRepeatable(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Directive", field.Name) + }, + } + return fc, nil +} + func (ec *executionContext) ___Type_kind(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Type_kind(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ - Object: "__Type", - Field: field, - Args: nil, - IsMethod: true, - IsResolver: false, - } - - ctx = graphql.WithFieldContext(ctx, fc) resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Kind(), nil @@ -12837,22 +16048,31 @@ func (ec *executionContext) ___Type_kind(ctx context.Context, field graphql.Coll return ec.marshalN__TypeKind2string(ctx, field.Selections, res) } -func (ec *executionContext) ___Type_name(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext___Type_kind(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "__Type", Field: field, - Args: nil, IsMethod: true, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type __TypeKind does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) ___Type_name(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Type_name(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Name(), nil @@ -12869,22 +16089,31 @@ func (ec *executionContext) ___Type_name(ctx context.Context, field graphql.Coll return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } -func (ec *executionContext) ___Type_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext___Type_name(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "__Type", Field: field, - Args: nil, IsMethod: true, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} +func (ec *executionContext) ___Type_description(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Type_description(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Description(), nil @@ -12901,32 +16130,34 @@ func (ec *executionContext) ___Type_description(ctx context.Context, field graph return ec.marshalOString2ᚖstring(ctx, field.Selections, res) } -func (ec *executionContext) ___Type_fields(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext___Type_description(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "__Type", Field: field, - Args: nil, IsMethod: true, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, } + return fc, nil +} - ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field___Type_fields_args(ctx, rawArgs) +func (ec *executionContext) ___Type_fields(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Type_fields(ctx, field) if err != nil { - ec.Error(ctx, err) return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.Fields(args["includeDeprecated"].(bool)), nil + return obj.Fields(fc.Args["includeDeprecated"].(bool)), nil }) if err != nil { ec.Error(ctx, err) @@ -12940,22 +16171,56 @@ func (ec *executionContext) ___Type_fields(ctx context.Context, field graphql.Co return ec.marshalO__Field2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐFieldᚄ(ctx, field.Selections, res) } -func (ec *executionContext) ___Type_interfaces(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext___Type_fields(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "__Type", Field: field, - Args: nil, IsMethod: true, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "name": + return ec.fieldContext___Field_name(ctx, field) + case "description": + return ec.fieldContext___Field_description(ctx, field) + case "args": + return ec.fieldContext___Field_args(ctx, field) + case "type": + return ec.fieldContext___Field_type(ctx, field) + case "isDeprecated": + return ec.fieldContext___Field_isDeprecated(ctx, field) + case "deprecationReason": + return ec.fieldContext___Field_deprecationReason(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Field", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field___Type_fields_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return } + return fc, nil +} +func (ec *executionContext) ___Type_interfaces(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Type_interfaces(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.Interfaces(), nil @@ -12972,22 +16237,53 @@ func (ec *executionContext) ___Type_interfaces(ctx context.Context, field graphq return ec.marshalO__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx, field.Selections, res) } -func (ec *executionContext) ___Type_possibleTypes(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext___Type_interfaces(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "__Type", Field: field, - Args: nil, IsMethod: true, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "kind": + return ec.fieldContext___Type_kind(ctx, field) + case "name": + return ec.fieldContext___Type_name(ctx, field) + case "description": + return ec.fieldContext___Type_description(ctx, field) + case "fields": + return ec.fieldContext___Type_fields(ctx, field) + case "interfaces": + return ec.fieldContext___Type_interfaces(ctx, field) + case "possibleTypes": + return ec.fieldContext___Type_possibleTypes(ctx, field) + case "enumValues": + return ec.fieldContext___Type_enumValues(ctx, field) + case "inputFields": + return ec.fieldContext___Type_inputFields(ctx, field) + case "ofType": + return ec.fieldContext___Type_ofType(ctx, field) + case "specifiedByURL": + return ec.fieldContext___Type_specifiedByURL(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) ___Type_possibleTypes(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Type_possibleTypes(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.PossibleTypes(), nil @@ -13004,32 +16300,56 @@ func (ec *executionContext) ___Type_possibleTypes(ctx context.Context, field gra return ec.marshalO__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐTypeᚄ(ctx, field.Selections, res) } -func (ec *executionContext) ___Type_enumValues(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext___Type_possibleTypes(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "__Type", Field: field, - Args: nil, IsMethod: true, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "kind": + return ec.fieldContext___Type_kind(ctx, field) + case "name": + return ec.fieldContext___Type_name(ctx, field) + case "description": + return ec.fieldContext___Type_description(ctx, field) + case "fields": + return ec.fieldContext___Type_fields(ctx, field) + case "interfaces": + return ec.fieldContext___Type_interfaces(ctx, field) + case "possibleTypes": + return ec.fieldContext___Type_possibleTypes(ctx, field) + case "enumValues": + return ec.fieldContext___Type_enumValues(ctx, field) + case "inputFields": + return ec.fieldContext___Type_inputFields(ctx, field) + case "ofType": + return ec.fieldContext___Type_ofType(ctx, field) + case "specifiedByURL": + return ec.fieldContext___Type_specifiedByURL(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) + }, } + return fc, nil +} - ctx = graphql.WithFieldContext(ctx, fc) - rawArgs := field.ArgumentMap(ec.Variables) - args, err := ec.field___Type_enumValues_args(ctx, rawArgs) +func (ec *executionContext) ___Type_enumValues(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Type_enumValues(ctx, field) if err != nil { - ec.Error(ctx, err) return graphql.Null } - fc.Args = args + ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.EnumValues(args["includeDeprecated"].(bool)), nil + return obj.EnumValues(fc.Args["includeDeprecated"].(bool)), nil }) if err != nil { ec.Error(ctx, err) @@ -13043,22 +16363,52 @@ func (ec *executionContext) ___Type_enumValues(ctx context.Context, field graphq return ec.marshalO__EnumValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐEnumValueᚄ(ctx, field.Selections, res) } -func (ec *executionContext) ___Type_inputFields(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { - defer func() { - if r := recover(); r != nil { - ec.Error(ctx, ec.Recover(ctx, r)) - ret = graphql.Null - } - }() - fc := &graphql.FieldContext{ +func (ec *executionContext) fieldContext___Type_enumValues(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "__Type", Field: field, - Args: nil, IsMethod: true, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "name": + return ec.fieldContext___EnumValue_name(ctx, field) + case "description": + return ec.fieldContext___EnumValue_description(ctx, field) + case "isDeprecated": + return ec.fieldContext___EnumValue_isDeprecated(ctx, field) + case "deprecationReason": + return ec.fieldContext___EnumValue_deprecationReason(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __EnumValue", field.Name) + }, + } + defer func() { + if r := recover(); r != nil { + err = ec.Recover(ctx, r) + ec.Error(ctx, err) + } + }() + ctx = graphql.WithFieldContext(ctx, fc) + if fc.Args, err = ec.field___Type_enumValues_args(ctx, field.ArgumentMap(ec.Variables)); err != nil { + ec.Error(ctx, err) + return } + return fc, nil +} +func (ec *executionContext) ___Type_inputFields(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Type_inputFields(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children return obj.InputFields(), nil @@ -13075,25 +16425,107 @@ func (ec *executionContext) ___Type_inputFields(ctx context.Context, field graph return ec.marshalO__InputValue2ᚕgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐInputValueᚄ(ctx, field.Selections, res) } +func (ec *executionContext) fieldContext___Type_inputFields(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Type", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "name": + return ec.fieldContext___InputValue_name(ctx, field) + case "description": + return ec.fieldContext___InputValue_description(ctx, field) + case "type": + return ec.fieldContext___InputValue_type(ctx, field) + case "defaultValue": + return ec.fieldContext___InputValue_defaultValue(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __InputValue", field.Name) + }, + } + return fc, nil +} + func (ec *executionContext) ___Type_ofType(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Type_ofType(ctx, field) + if err != nil { + return graphql.Null + } + ctx = graphql.WithFieldContext(ctx, fc) defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) ret = graphql.Null } }() - fc := &graphql.FieldContext{ + resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { + ctx = rctx // use context from middleware stack in children + return obj.OfType(), nil + }) + if err != nil { + ec.Error(ctx, err) + return graphql.Null + } + if resTmp == nil { + return graphql.Null + } + res := resTmp.(*introspection.Type) + fc.Result = res + return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Type_ofType(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ Object: "__Type", Field: field, - Args: nil, IsMethod: true, IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + switch field.Name { + case "kind": + return ec.fieldContext___Type_kind(ctx, field) + case "name": + return ec.fieldContext___Type_name(ctx, field) + case "description": + return ec.fieldContext___Type_description(ctx, field) + case "fields": + return ec.fieldContext___Type_fields(ctx, field) + case "interfaces": + return ec.fieldContext___Type_interfaces(ctx, field) + case "possibleTypes": + return ec.fieldContext___Type_possibleTypes(ctx, field) + case "enumValues": + return ec.fieldContext___Type_enumValues(ctx, field) + case "inputFields": + return ec.fieldContext___Type_inputFields(ctx, field) + case "ofType": + return ec.fieldContext___Type_ofType(ctx, field) + case "specifiedByURL": + return ec.fieldContext___Type_specifiedByURL(ctx, field) + } + return nil, fmt.Errorf("no field named %q was found under type __Type", field.Name) + }, } + return fc, nil +} +func (ec *executionContext) ___Type_specifiedByURL(ctx context.Context, field graphql.CollectedField, obj *introspection.Type) (ret graphql.Marshaler) { + fc, err := ec.fieldContext___Type_specifiedByURL(ctx, field) + if err != nil { + return graphql.Null + } ctx = graphql.WithFieldContext(ctx, fc) + defer func() { + if r := recover(); r != nil { + ec.Error(ctx, ec.Recover(ctx, r)) + ret = graphql.Null + } + }() resTmp, err := ec.ResolverMiddleware(ctx, func(rctx context.Context) (interface{}, error) { ctx = rctx // use context from middleware stack in children - return obj.OfType(), nil + return obj.SpecifiedByURL(), nil }) if err != nil { ec.Error(ctx, err) @@ -13102,9 +16534,22 @@ func (ec *executionContext) ___Type_ofType(ctx context.Context, field graphql.Co if resTmp == nil { return graphql.Null } - res := resTmp.(*introspection.Type) + res := resTmp.(*string) fc.Result = res - return ec.marshalO__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx, field.Selections, res) + return ec.marshalOString2ᚖstring(ctx, field.Selections, res) +} + +func (ec *executionContext) fieldContext___Type_specifiedByURL(ctx context.Context, field graphql.CollectedField) (fc *graphql.FieldContext, err error) { + fc = &graphql.FieldContext{ + Object: "__Type", + Field: field, + IsMethod: true, + IsResolver: false, + Child: func(ctx context.Context, field graphql.CollectedField) (*graphql.FieldContext, error) { + return nil, errors.New("field of type String does not have child fields") + }, + } + return fc, nil } // endregion **************************** field.gotpl ***************************** @@ -13118,7 +16563,12 @@ func (ec *executionContext) unmarshalInputCreateBusinessDetailInput(ctx context. asMap[k] = v } - for k, v := range asMap { + fieldsInOrder := [...]string{"name", "website", "logo"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } switch k { case "name": var err error @@ -13157,7 +16607,12 @@ func (ec *executionContext) unmarshalInputCreateChannelRequestInput(ctx context. asMap[k] = v } - for k, v := range asMap { + fieldsInOrder := [...]string{"paymentHash", "paymentAddr", "amountMsat"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } switch k { case "paymentHash": var err error @@ -13196,7 +16651,12 @@ func (ec *executionContext) unmarshalInputCreateCredentialInput(ctx context.Cont asMap[k] = v } - for k, v := range asMap { + fieldsInOrder := [...]string{"clientToken", "url", "businessDetail", "countryCode", "partyId", "isHub"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } switch k { case "clientToken": var err error @@ -13259,7 +16719,12 @@ func (ec *executionContext) unmarshalInputCreateEmailSubscriptionInput(ctx conte asMap[k] = v } - for k, v := range asMap { + fieldsInOrder := [...]string{"email", "locale"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } switch k { case "email": var err error @@ -13290,7 +16755,12 @@ func (ec *executionContext) unmarshalInputCreateImageInput(ctx context.Context, asMap[k] = v } - for k, v := range asMap { + fieldsInOrder := [...]string{"url", "thumbnail", "category", "type", "width", "height"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } switch k { case "url": var err error @@ -13353,7 +16823,12 @@ func (ec *executionContext) unmarshalInputCreateReferralInput(ctx context.Contex asMap[k] = v } - for k, v := range asMap { + fieldsInOrder := [...]string{"code", "referrer"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } switch k { case "code": var err error @@ -13384,7 +16859,12 @@ func (ec *executionContext) unmarshalInputCreateUserInput(ctx context.Context, o asMap[k] = v } - for k, v := range asMap { + fieldsInOrder := [...]string{"code", "pubkey", "deviceToken"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } switch k { case "code": var err error @@ -13423,7 +16903,12 @@ func (ec *executionContext) unmarshalInputGetLocationInput(ctx context.Context, asMap[k] = v } - for k, v := range asMap { + fieldsInOrder := [...]string{"id", "uid"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } switch k { case "id": var err error @@ -13454,7 +16939,12 @@ func (ec *executionContext) unmarshalInputGetSessionInput(ctx context.Context, o asMap[k] = v } - for k, v := range asMap { + fieldsInOrder := [...]string{"id", "uid", "authorizationId"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } switch k { case "id": var err error @@ -13493,7 +16983,12 @@ func (ec *executionContext) unmarshalInputGetTariffInput(ctx context.Context, ob asMap[k] = v } - for k, v := range asMap { + fieldsInOrder := [...]string{"id", "uid", "country"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } switch k { case "id": var err error @@ -13532,7 +17027,12 @@ func (ec *executionContext) unmarshalInputListLocationsInput(ctx context.Context asMap[k] = v } - for k, v := range asMap { + fieldsInOrder := [...]string{"xMin", "yMin", "xMax", "yMax", "interval"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } switch k { case "xMin": var err error @@ -13587,7 +17087,12 @@ func (ec *executionContext) unmarshalInputPublishLocationInput(ctx context.Conte asMap[k] = v } - for k, v := range asMap { + fieldsInOrder := [...]string{"id", "credentialId", "countryCode", "partyId", "publish"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } switch k { case "id": var err error @@ -13642,7 +17147,12 @@ func (ec *executionContext) unmarshalInputRegisterCredentialInput(ctx context.Co asMap[k] = v } - for k, v := range asMap { + fieldsInOrder := [...]string{"id", "clientToken"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } switch k { case "id": var err error @@ -13673,7 +17183,12 @@ func (ec *executionContext) unmarshalInputStartSessionInput(ctx context.Context, asMap[k] = v } - for k, v := range asMap { + fieldsInOrder := [...]string{"locationUid", "evseUid"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } switch k { case "locationUid": var err error @@ -13704,7 +17219,12 @@ func (ec *executionContext) unmarshalInputStopSessionInput(ctx context.Context, asMap[k] = v } - for k, v := range asMap { + fieldsInOrder := [...]string{"sessionUid"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } switch k { case "sessionUid": var err error @@ -13720,6 +17240,58 @@ func (ec *executionContext) unmarshalInputStopSessionInput(ctx context.Context, return it, nil } +func (ec *executionContext) unmarshalInputSyncCredentialInput(ctx context.Context, obj interface{}) (SyncCredentialInput, error) { + var it SyncCredentialInput + asMap := map[string]interface{}{} + for k, v := range obj.(map[string]interface{}) { + asMap[k] = v + } + + fieldsInOrder := [...]string{"id", "fromDate", "countryCode", "partyId"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } + switch k { + case "id": + var err error + + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("id")) + it.ID, err = ec.unmarshalNID2int64(ctx, v) + if err != nil { + return it, err + } + case "fromDate": + var err error + + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("fromDate")) + it.FromDate, err = ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + case "countryCode": + var err error + + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("countryCode")) + it.CountryCode, err = ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + case "partyId": + var err error + + ctx := graphql.WithPathContext(ctx, graphql.NewPathWithField("partyId")) + it.PartyID, err = ec.unmarshalOString2ᚖstring(ctx, v) + if err != nil { + return it, err + } + } + } + + return it, nil +} + func (ec *executionContext) unmarshalInputUnregisterCredentialInput(ctx context.Context, obj interface{}) (UnregisterCredentialInput, error) { var it UnregisterCredentialInput asMap := map[string]interface{}{} @@ -13727,7 +17299,12 @@ func (ec *executionContext) unmarshalInputUnregisterCredentialInput(ctx context. asMap[k] = v } - for k, v := range asMap { + fieldsInOrder := [...]string{"id"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } switch k { case "id": var err error @@ -13750,7 +17327,12 @@ func (ec *executionContext) unmarshalInputUpdateInvoiceRequestInput(ctx context. asMap[k] = v } - for k, v := range asMap { + fieldsInOrder := [...]string{"id", "paymentRequest"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } switch k { case "id": var err error @@ -13781,7 +17363,12 @@ func (ec *executionContext) unmarshalInputUpdateUserInput(ctx context.Context, o asMap[k] = v } - for k, v := range asMap { + fieldsInOrder := [...]string{"deviceToken"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } switch k { case "deviceToken": var err error @@ -13804,7 +17391,12 @@ func (ec *executionContext) unmarshalInputVerifyEmailSubscriptionInput(ctx conte asMap[k] = v } - for k, v := range asMap { + fieldsInOrder := [...]string{"email", "verificationCode"} + for _, k := range fieldsInOrder { + v, ok := asMap[k] + if !ok { + continue + } switch k { case "email": var err error @@ -13840,7 +17432,6 @@ var addtionalGeoLocationImplementors = []string{"AddtionalGeoLocation"} func (ec *executionContext) _AddtionalGeoLocation(ctx context.Context, sel ast.SelectionSet, obj *AddtionalGeoLocation) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, addtionalGeoLocationImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -13848,17 +17439,23 @@ func (ec *executionContext) _AddtionalGeoLocation(ctx context.Context, sel ast.S case "__typename": out.Values[i] = graphql.MarshalString("AddtionalGeoLocation") case "latitude": + out.Values[i] = ec._AddtionalGeoLocation_latitude(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "longitude": + out.Values[i] = ec._AddtionalGeoLocation_longitude(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "name": + out.Values[i] = ec._AddtionalGeoLocation_name(ctx, field, obj) + default: panic("unknown field " + strconv.Quote(field.Name)) } @@ -13874,7 +17471,6 @@ var businessDetailImplementors = []string{"BusinessDetail"} func (ec *executionContext) _BusinessDetail(ctx context.Context, sel ast.SelectionSet, obj *db.BusinessDetail) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, businessDetailImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -13882,13 +17478,16 @@ func (ec *executionContext) _BusinessDetail(ctx context.Context, sel ast.Selecti case "__typename": out.Values[i] = graphql.MarshalString("BusinessDetail") case "name": + out.Values[i] = ec._BusinessDetail_name(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "website": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -13896,10 +17495,16 @@ func (ec *executionContext) _BusinessDetail(ctx context.Context, sel ast.Selecti }() res = ec._BusinessDetail_website(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "logo": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -13907,6 +17512,11 @@ func (ec *executionContext) _BusinessDetail(ctx context.Context, sel ast.Selecti }() res = ec._BusinessDetail_logo(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) default: panic("unknown field " + strconv.Quote(field.Name)) @@ -13923,7 +17533,6 @@ var channelRequestImplementors = []string{"ChannelRequest"} func (ec *executionContext) _ChannelRequest(ctx context.Context, sel ast.SelectionSet, obj *db.ChannelRequest) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, channelRequestImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -13931,13 +17540,16 @@ func (ec *executionContext) _ChannelRequest(ctx context.Context, sel ast.Selecti case "__typename": out.Values[i] = graphql.MarshalString("ChannelRequest") case "id": + out.Values[i] = ec._ChannelRequest_id(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "paymentHash": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -13948,10 +17560,16 @@ func (ec *executionContext) _ChannelRequest(ctx context.Context, sel ast.Selecti atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "paymentAddr": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -13962,10 +17580,16 @@ func (ec *executionContext) _ChannelRequest(ctx context.Context, sel ast.Selecti atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "amountMsat": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -13976,10 +17600,16 @@ func (ec *executionContext) _ChannelRequest(ctx context.Context, sel ast.Selecti atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "node": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -13990,10 +17620,16 @@ func (ec *executionContext) _ChannelRequest(ctx context.Context, sel ast.Selecti atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "pendingChanId": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14004,10 +17640,16 @@ func (ec *executionContext) _ChannelRequest(ctx context.Context, sel ast.Selecti atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "scid": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14018,19 +17660,30 @@ func (ec *executionContext) _ChannelRequest(ctx context.Context, sel ast.Selecti atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "feeBaseMsat": + out.Values[i] = ec._ChannelRequest_feeBaseMsat(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "feeProportionalMillionths": + out.Values[i] = ec._ChannelRequest_feeProportionalMillionths(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "cltvExpiryDelta": + out.Values[i] = ec._ChannelRequest_cltvExpiryDelta(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } @@ -14049,7 +17702,6 @@ var connectorImplementors = []string{"Connector"} func (ec *executionContext) _Connector(ctx context.Context, sel ast.SelectionSet, obj *db.Connector) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, connectorImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -14057,18 +17709,23 @@ func (ec *executionContext) _Connector(ctx context.Context, sel ast.SelectionSet case "__typename": out.Values[i] = graphql.MarshalString("Connector") case "id": + out.Values[i] = ec._Connector_id(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "uid": + out.Values[i] = ec._Connector_uid(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "identifier": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14076,10 +17733,16 @@ func (ec *executionContext) _Connector(ctx context.Context, sel ast.SelectionSet }() res = ec._Connector_identifier(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "standard": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14090,10 +17753,16 @@ func (ec *executionContext) _Connector(ctx context.Context, sel ast.SelectionSet atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "format": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14104,10 +17773,16 @@ func (ec *executionContext) _Connector(ctx context.Context, sel ast.SelectionSet atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "powerType": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14118,25 +17793,37 @@ func (ec *executionContext) _Connector(ctx context.Context, sel ast.SelectionSet atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "voltage": + out.Values[i] = ec._Connector_voltage(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "amperage": + out.Values[i] = ec._Connector_amperage(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "wattage": + out.Values[i] = ec._Connector_wattage(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "tariffId": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14144,10 +17831,16 @@ func (ec *executionContext) _Connector(ctx context.Context, sel ast.SelectionSet }() res = ec._Connector_tariffId(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "tariff": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14155,10 +17848,16 @@ func (ec *executionContext) _Connector(ctx context.Context, sel ast.SelectionSet }() res = ec._Connector_tariff(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "termsAndConditions": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14166,10 +17865,16 @@ func (ec *executionContext) _Connector(ctx context.Context, sel ast.SelectionSet }() res = ec._Connector_termsAndConditions(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "lastUpdated": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14180,6 +17885,11 @@ func (ec *executionContext) _Connector(ctx context.Context, sel ast.SelectionSet atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) default: panic("unknown field " + strconv.Quote(field.Name)) @@ -14196,7 +17906,6 @@ var createAuthenticationImplementors = []string{"CreateAuthentication"} func (ec *executionContext) _CreateAuthentication(ctx context.Context, sel ast.SelectionSet, obj *CreateAuthentication) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, createAuthenticationImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -14204,12 +17913,16 @@ func (ec *executionContext) _CreateAuthentication(ctx context.Context, sel ast.S case "__typename": out.Values[i] = graphql.MarshalString("CreateAuthentication") case "code": + out.Values[i] = ec._CreateAuthentication_code(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "lnUrl": + out.Values[i] = ec._CreateAuthentication_lnUrl(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } @@ -14228,7 +17941,6 @@ var credentialImplementors = []string{"Credential"} func (ec *executionContext) _Credential(ctx context.Context, sel ast.SelectionSet, obj *db.Credential) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, credentialImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -14236,27 +17948,37 @@ func (ec *executionContext) _Credential(ctx context.Context, sel ast.SelectionSe case "__typename": out.Values[i] = graphql.MarshalString("Credential") case "id": + out.Values[i] = ec._Credential_id(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "url": + out.Values[i] = ec._Credential_url(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "countryCode": + out.Values[i] = ec._Credential_countryCode(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "partyId": + out.Values[i] = ec._Credential_partyId(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "isHub": + out.Values[i] = ec._Credential_isHub(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } @@ -14275,7 +17997,6 @@ var displayTextImplementors = []string{"DisplayText"} func (ec *executionContext) _DisplayText(ctx context.Context, sel ast.SelectionSet, obj *db.DisplayText) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, displayTextImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -14283,12 +18004,16 @@ func (ec *executionContext) _DisplayText(ctx context.Context, sel ast.SelectionS case "__typename": out.Values[i] = graphql.MarshalString("DisplayText") case "language": + out.Values[i] = ec._DisplayText_language(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "text": + out.Values[i] = ec._DisplayText_text(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } @@ -14307,7 +18032,6 @@ var elementRestrictionImplementors = []string{"ElementRestriction"} func (ec *executionContext) _ElementRestriction(ctx context.Context, sel ast.SelectionSet, obj *db.ElementRestriction) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, elementRestrictionImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -14316,7 +18040,8 @@ func (ec *executionContext) _ElementRestriction(ctx context.Context, sel ast.Sel out.Values[i] = graphql.MarshalString("ElementRestriction") case "startTime": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14324,10 +18049,16 @@ func (ec *executionContext) _ElementRestriction(ctx context.Context, sel ast.Sel }() res = ec._ElementRestriction_startTime(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "endTime": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14335,10 +18066,16 @@ func (ec *executionContext) _ElementRestriction(ctx context.Context, sel ast.Sel }() res = ec._ElementRestriction_endTime(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "startDate": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14346,10 +18083,16 @@ func (ec *executionContext) _ElementRestriction(ctx context.Context, sel ast.Sel }() res = ec._ElementRestriction_startDate(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "endDate": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14357,10 +18100,16 @@ func (ec *executionContext) _ElementRestriction(ctx context.Context, sel ast.Sel }() res = ec._ElementRestriction_endDate(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "minKwh": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14368,10 +18117,16 @@ func (ec *executionContext) _ElementRestriction(ctx context.Context, sel ast.Sel }() res = ec._ElementRestriction_minKwh(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "maxKwh": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14379,10 +18134,16 @@ func (ec *executionContext) _ElementRestriction(ctx context.Context, sel ast.Sel }() res = ec._ElementRestriction_maxKwh(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "minPower": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14390,10 +18151,16 @@ func (ec *executionContext) _ElementRestriction(ctx context.Context, sel ast.Sel }() res = ec._ElementRestriction_minPower(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "maxPower": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14401,10 +18168,16 @@ func (ec *executionContext) _ElementRestriction(ctx context.Context, sel ast.Sel }() res = ec._ElementRestriction_maxPower(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "minDuration": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14412,10 +18185,16 @@ func (ec *executionContext) _ElementRestriction(ctx context.Context, sel ast.Sel }() res = ec._ElementRestriction_minDuration(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "maxDuration": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14423,10 +18202,16 @@ func (ec *executionContext) _ElementRestriction(ctx context.Context, sel ast.Sel }() res = ec._ElementRestriction_maxDuration(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "dayOfWeek": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14434,6 +18219,11 @@ func (ec *executionContext) _ElementRestriction(ctx context.Context, sel ast.Sel }() res = ec._ElementRestriction_dayOfWeek(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) default: panic("unknown field " + strconv.Quote(field.Name)) @@ -14450,7 +18240,6 @@ var emailSubscriptionImplementors = []string{"EmailSubscription"} func (ec *executionContext) _EmailSubscription(ctx context.Context, sel ast.SelectionSet, obj *db.EmailSubscription) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, emailSubscriptionImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -14458,22 +18247,30 @@ func (ec *executionContext) _EmailSubscription(ctx context.Context, sel ast.Sele case "__typename": out.Values[i] = graphql.MarshalString("EmailSubscription") case "id": + out.Values[i] = ec._EmailSubscription_id(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "email": + out.Values[i] = ec._EmailSubscription_email(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "locale": + out.Values[i] = ec._EmailSubscription_locale(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "isVerified": + out.Values[i] = ec._EmailSubscription_isVerified(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } @@ -14492,7 +18289,6 @@ var energyMixImplementors = []string{"EnergyMix"} func (ec *executionContext) _EnergyMix(ctx context.Context, sel ast.SelectionSet, obj *db.EnergyMix) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, energyMixImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -14500,13 +18296,16 @@ func (ec *executionContext) _EnergyMix(ctx context.Context, sel ast.SelectionSet case "__typename": out.Values[i] = graphql.MarshalString("EnergyMix") case "isGreenEnergy": + out.Values[i] = ec._EnergyMix_isGreenEnergy(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "energySources": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14517,10 +18316,16 @@ func (ec *executionContext) _EnergyMix(ctx context.Context, sel ast.SelectionSet atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "environmentalImpact": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14531,10 +18336,16 @@ func (ec *executionContext) _EnergyMix(ctx context.Context, sel ast.SelectionSet atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "supplierName": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14542,10 +18353,16 @@ func (ec *executionContext) _EnergyMix(ctx context.Context, sel ast.SelectionSet }() res = ec._EnergyMix_supplierName(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "energyProductName": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14553,6 +18370,11 @@ func (ec *executionContext) _EnergyMix(ctx context.Context, sel ast.SelectionSet }() res = ec._EnergyMix_energyProductName(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) default: panic("unknown field " + strconv.Quote(field.Name)) @@ -14569,7 +18391,6 @@ var energySourceImplementors = []string{"EnergySource"} func (ec *executionContext) _EnergySource(ctx context.Context, sel ast.SelectionSet, obj *db.EnergySource) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, energySourceImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -14578,7 +18399,8 @@ func (ec *executionContext) _EnergySource(ctx context.Context, sel ast.Selection out.Values[i] = graphql.MarshalString("EnergySource") case "source": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14589,9 +18411,16 @@ func (ec *executionContext) _EnergySource(ctx context.Context, sel ast.Selection atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "percentage": + out.Values[i] = ec._EnergySource_percentage(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } @@ -14610,7 +18439,6 @@ var environmentalImpactImplementors = []string{"EnvironmentalImpact"} func (ec *executionContext) _EnvironmentalImpact(ctx context.Context, sel ast.SelectionSet, obj *db.EnvironmentalImpact) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, environmentalImpactImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -14619,7 +18447,8 @@ func (ec *executionContext) _EnvironmentalImpact(ctx context.Context, sel ast.Se out.Values[i] = graphql.MarshalString("EnvironmentalImpact") case "source": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14630,9 +18459,16 @@ func (ec *executionContext) _EnvironmentalImpact(ctx context.Context, sel ast.Se atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "amount": + out.Values[i] = ec._EnvironmentalImpact_amount(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } @@ -14651,7 +18487,6 @@ var evseImplementors = []string{"Evse"} func (ec *executionContext) _Evse(ctx context.Context, sel ast.SelectionSet, obj *db.Evse) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, evseImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -14659,18 +18494,23 @@ func (ec *executionContext) _Evse(ctx context.Context, sel ast.SelectionSet, obj case "__typename": out.Values[i] = graphql.MarshalString("Evse") case "id": + out.Values[i] = ec._Evse_id(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "uid": + out.Values[i] = ec._Evse_uid(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "identifier": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14678,10 +18518,16 @@ func (ec *executionContext) _Evse(ctx context.Context, sel ast.SelectionSet, obj }() res = ec._Evse_identifier(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "status": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14692,10 +18538,16 @@ func (ec *executionContext) _Evse(ctx context.Context, sel ast.SelectionSet, obj atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "statusSchedule": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14706,10 +18558,16 @@ func (ec *executionContext) _Evse(ctx context.Context, sel ast.SelectionSet, obj atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "capabilities": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14720,10 +18578,16 @@ func (ec *executionContext) _Evse(ctx context.Context, sel ast.SelectionSet, obj atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "connectors": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14734,10 +18598,16 @@ func (ec *executionContext) _Evse(ctx context.Context, sel ast.SelectionSet, obj atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "floorLevel": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14745,10 +18615,16 @@ func (ec *executionContext) _Evse(ctx context.Context, sel ast.SelectionSet, obj }() res = ec._Evse_floorLevel(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "geom": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14756,20 +18632,30 @@ func (ec *executionContext) _Evse(ctx context.Context, sel ast.SelectionSet, obj }() res = ec._Evse_geom(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "isRemoteCapable": + out.Values[i] = ec._Evse_isRemoteCapable(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "isRfidCapable": + out.Values[i] = ec._Evse_isRfidCapable(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "physicalReference": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14777,10 +18663,16 @@ func (ec *executionContext) _Evse(ctx context.Context, sel ast.SelectionSet, obj }() res = ec._Evse_physicalReference(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "directions": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14791,10 +18683,16 @@ func (ec *executionContext) _Evse(ctx context.Context, sel ast.SelectionSet, obj atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "parkingRestrictions": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14805,10 +18703,16 @@ func (ec *executionContext) _Evse(ctx context.Context, sel ast.SelectionSet, obj atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "images": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14819,10 +18723,16 @@ func (ec *executionContext) _Evse(ctx context.Context, sel ast.SelectionSet, obj atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "lastUpdated": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14833,6 +18743,11 @@ func (ec *executionContext) _Evse(ctx context.Context, sel ast.SelectionSet, obj atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) default: panic("unknown field " + strconv.Quote(field.Name)) @@ -14849,7 +18764,6 @@ var exceptionalPeriodImplementors = []string{"ExceptionalPeriod"} func (ec *executionContext) _ExceptionalPeriod(ctx context.Context, sel ast.SelectionSet, obj *db.ExceptionalPeriod) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, exceptionalPeriodImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -14858,7 +18772,8 @@ func (ec *executionContext) _ExceptionalPeriod(ctx context.Context, sel ast.Sele out.Values[i] = graphql.MarshalString("ExceptionalPeriod") case "periodBegin": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14869,10 +18784,16 @@ func (ec *executionContext) _ExceptionalPeriod(ctx context.Context, sel ast.Sele atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "periodEnd": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14883,6 +18804,11 @@ func (ec *executionContext) _ExceptionalPeriod(ctx context.Context, sel ast.Sele atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) default: panic("unknown field " + strconv.Quote(field.Name)) @@ -14899,7 +18825,6 @@ var exchangeAuthenticationImplementors = []string{"ExchangeAuthentication"} func (ec *executionContext) _ExchangeAuthentication(ctx context.Context, sel ast.SelectionSet, obj *ExchangeAuthentication) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, exchangeAuthenticationImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -14907,7 +18832,9 @@ func (ec *executionContext) _ExchangeAuthentication(ctx context.Context, sel ast case "__typename": out.Values[i] = graphql.MarshalString("ExchangeAuthentication") case "token": + out.Values[i] = ec._ExchangeAuthentication_token(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } @@ -14926,7 +18853,6 @@ var geolocationImplementors = []string{"Geolocation"} func (ec *executionContext) _Geolocation(ctx context.Context, sel ast.SelectionSet, obj *Geolocation) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, geolocationImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -14934,17 +18860,23 @@ func (ec *executionContext) _Geolocation(ctx context.Context, sel ast.SelectionS case "__typename": out.Values[i] = graphql.MarshalString("Geolocation") case "latitude": + out.Values[i] = ec._Geolocation_latitude(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "longitude": + out.Values[i] = ec._Geolocation_longitude(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "name": + out.Values[i] = ec._Geolocation_name(ctx, field, obj) + default: panic("unknown field " + strconv.Quote(field.Name)) } @@ -14960,7 +18892,6 @@ var imageImplementors = []string{"Image"} func (ec *executionContext) _Image(ctx context.Context, sel ast.SelectionSet, obj *db.Image) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, imageImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -14968,13 +18899,16 @@ func (ec *executionContext) _Image(ctx context.Context, sel ast.SelectionSet, ob case "__typename": out.Values[i] = graphql.MarshalString("Image") case "url": + out.Values[i] = ec._Image_url(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "thumbnail": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14982,10 +18916,16 @@ func (ec *executionContext) _Image(ctx context.Context, sel ast.SelectionSet, ob }() res = ec._Image_thumbnail(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "category": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -14996,15 +18936,23 @@ func (ec *executionContext) _Image(ctx context.Context, sel ast.SelectionSet, ob atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "type": + out.Values[i] = ec._Image_type(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "width": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15012,10 +18960,16 @@ func (ec *executionContext) _Image(ctx context.Context, sel ast.SelectionSet, ob }() res = ec._Image_width(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "height": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15023,6 +18977,11 @@ func (ec *executionContext) _Image(ctx context.Context, sel ast.SelectionSet, ob }() res = ec._Image_height(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) default: panic("unknown field " + strconv.Quote(field.Name)) @@ -15039,7 +18998,6 @@ var invoiceRequestImplementors = []string{"InvoiceRequest"} func (ec *executionContext) _InvoiceRequest(ctx context.Context, sel ast.SelectionSet, obj *db.InvoiceRequest) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, invoiceRequestImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -15047,13 +19005,16 @@ func (ec *executionContext) _InvoiceRequest(ctx context.Context, sel ast.Selecti case "__typename": out.Values[i] = graphql.MarshalString("InvoiceRequest") case "id": + out.Values[i] = ec._InvoiceRequest_id(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "promotion": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15064,20 +19025,30 @@ func (ec *executionContext) _InvoiceRequest(ctx context.Context, sel ast.Selecti atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "currency": + out.Values[i] = ec._InvoiceRequest_currency(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "memo": + out.Values[i] = ec._InvoiceRequest_memo(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "priceFiat": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15085,10 +19056,16 @@ func (ec *executionContext) _InvoiceRequest(ctx context.Context, sel ast.Selecti }() res = ec._InvoiceRequest_priceFiat(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "priceMsat": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15096,10 +19073,16 @@ func (ec *executionContext) _InvoiceRequest(ctx context.Context, sel ast.Selecti }() res = ec._InvoiceRequest_priceMsat(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "commissionFiat": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15107,10 +19090,16 @@ func (ec *executionContext) _InvoiceRequest(ctx context.Context, sel ast.Selecti }() res = ec._InvoiceRequest_commissionFiat(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "commissionMsat": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15118,10 +19107,16 @@ func (ec *executionContext) _InvoiceRequest(ctx context.Context, sel ast.Selecti }() res = ec._InvoiceRequest_commissionMsat(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "taxFiat": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15129,10 +19124,16 @@ func (ec *executionContext) _InvoiceRequest(ctx context.Context, sel ast.Selecti }() res = ec._InvoiceRequest_taxFiat(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "taxMsat": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15140,14 +19141,23 @@ func (ec *executionContext) _InvoiceRequest(ctx context.Context, sel ast.Selecti }() res = ec._InvoiceRequest_taxMsat(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "totalFiat": + out.Values[i] = ec._InvoiceRequest_totalFiat(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "totalMsat": + out.Values[i] = ec._InvoiceRequest_totalMsat(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } @@ -15166,7 +19176,6 @@ var listLocationImplementors = []string{"ListLocation"} func (ec *executionContext) _ListLocation(ctx context.Context, sel ast.SelectionSet, obj *ListLocation) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, listLocationImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -15174,37 +19183,51 @@ func (ec *executionContext) _ListLocation(ctx context.Context, sel ast.Selection case "__typename": out.Values[i] = graphql.MarshalString("ListLocation") case "uid": + out.Values[i] = ec._ListLocation_uid(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "name": + out.Values[i] = ec._ListLocation_name(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "geom": + out.Values[i] = ec._ListLocation_geom(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "availableEvses": + out.Values[i] = ec._ListLocation_availableEvses(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "totalEvses": + out.Values[i] = ec._ListLocation_totalEvses(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "isRemoteCapable": + out.Values[i] = ec._ListLocation_isRemoteCapable(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "isRfidCapable": + out.Values[i] = ec._ListLocation_isRfidCapable(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } @@ -15223,7 +19246,6 @@ var locationImplementors = []string{"Location"} func (ec *executionContext) _Location(ctx context.Context, sel ast.SelectionSet, obj *db.Location) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, locationImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -15231,18 +19253,23 @@ func (ec *executionContext) _Location(ctx context.Context, sel ast.SelectionSet, case "__typename": out.Values[i] = graphql.MarshalString("Location") case "id": + out.Values[i] = ec._Location_id(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "uid": + out.Values[i] = ec._Location_uid(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "type": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15253,10 +19280,16 @@ func (ec *executionContext) _Location(ctx context.Context, sel ast.SelectionSet, atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "name": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15264,35 +19297,51 @@ func (ec *executionContext) _Location(ctx context.Context, sel ast.SelectionSet, }() res = ec._Location_name(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "address": + out.Values[i] = ec._Location_address(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "city": + out.Values[i] = ec._Location_city(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "postalCode": + out.Values[i] = ec._Location_postalCode(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "country": + out.Values[i] = ec._Location_country(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "geom": + out.Values[i] = ec._Location_geom(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "relatedLocations": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15303,10 +19352,16 @@ func (ec *executionContext) _Location(ctx context.Context, sel ast.SelectionSet, atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "evses": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15317,30 +19372,44 @@ func (ec *executionContext) _Location(ctx context.Context, sel ast.SelectionSet, atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "availableEvses": + out.Values[i] = ec._Location_availableEvses(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "totalEvses": + out.Values[i] = ec._Location_totalEvses(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "isRemoteCapable": + out.Values[i] = ec._Location_isRemoteCapable(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "isRfidCapable": + out.Values[i] = ec._Location_isRfidCapable(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "directions": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15351,10 +19420,16 @@ func (ec *executionContext) _Location(ctx context.Context, sel ast.SelectionSet, atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "operator": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15362,10 +19437,16 @@ func (ec *executionContext) _Location(ctx context.Context, sel ast.SelectionSet, }() res = ec._Location_operator(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "suboperator": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15373,10 +19454,16 @@ func (ec *executionContext) _Location(ctx context.Context, sel ast.SelectionSet, }() res = ec._Location_suboperator(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "owner": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15384,10 +19471,16 @@ func (ec *executionContext) _Location(ctx context.Context, sel ast.SelectionSet, }() res = ec._Location_owner(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "facilities": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15398,10 +19491,16 @@ func (ec *executionContext) _Location(ctx context.Context, sel ast.SelectionSet, atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "timeZone": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15409,10 +19508,16 @@ func (ec *executionContext) _Location(ctx context.Context, sel ast.SelectionSet, }() res = ec._Location_timeZone(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "openingTime": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15420,15 +19525,23 @@ func (ec *executionContext) _Location(ctx context.Context, sel ast.SelectionSet, }() res = ec._Location_openingTime(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "chargingWhenClosed": + out.Values[i] = ec._Location_chargingWhenClosed(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "images": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15439,10 +19552,16 @@ func (ec *executionContext) _Location(ctx context.Context, sel ast.SelectionSet, atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "energyMix": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15450,10 +19569,16 @@ func (ec *executionContext) _Location(ctx context.Context, sel ast.SelectionSet, }() res = ec._Location_energyMix(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "lastUpdated": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15464,6 +19589,11 @@ func (ec *executionContext) _Location(ctx context.Context, sel ast.SelectionSet, atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) default: panic("unknown field " + strconv.Quote(field.Name)) @@ -15480,7 +19610,6 @@ var mutationImplementors = []string{"Mutation"} func (ec *executionContext) _Mutation(ctx context.Context, sel ast.SelectionSet) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, mutationImplementors) - ctx = graphql.WithFieldContext(ctx, &graphql.FieldContext{ Object: "Mutation", }) @@ -15488,81 +19617,155 @@ func (ec *executionContext) _Mutation(ctx context.Context, sel ast.SelectionSet) out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { + innerCtx := graphql.WithRootFieldContext(ctx, &graphql.RootFieldContext{ + Object: field.Name, + Field: field, + }) + switch field.Name { case "__typename": out.Values[i] = graphql.MarshalString("Mutation") case "createAuthentication": - out.Values[i] = ec._Mutation_createAuthentication(ctx, field) + + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_createAuthentication(ctx, field) + }) + if out.Values[i] == graphql.Null { invalids++ } case "exchangeAuthentication": - out.Values[i] = ec._Mutation_exchangeAuthentication(ctx, field) + + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_exchangeAuthentication(ctx, field) + }) + if out.Values[i] == graphql.Null { invalids++ } case "createChannelRequest": - out.Values[i] = ec._Mutation_createChannelRequest(ctx, field) + + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_createChannelRequest(ctx, field) + }) + if out.Values[i] == graphql.Null { invalids++ } case "startSession": - out.Values[i] = ec._Mutation_startSession(ctx, field) + + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_startSession(ctx, field) + }) + if out.Values[i] == graphql.Null { invalids++ } case "stopSession": - out.Values[i] = ec._Mutation_stopSession(ctx, field) + + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_stopSession(ctx, field) + }) + if out.Values[i] == graphql.Null { invalids++ } case "createCredential": - out.Values[i] = ec._Mutation_createCredential(ctx, field) + + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_createCredential(ctx, field) + }) + if out.Values[i] == graphql.Null { invalids++ } case "registerCredential": - out.Values[i] = ec._Mutation_registerCredential(ctx, field) + + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_registerCredential(ctx, field) + }) + + if out.Values[i] == graphql.Null { + invalids++ + } + case "syncCredential": + + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_syncCredential(ctx, field) + }) + if out.Values[i] == graphql.Null { invalids++ } case "unregisterCredential": - out.Values[i] = ec._Mutation_unregisterCredential(ctx, field) + + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_unregisterCredential(ctx, field) + }) + if out.Values[i] == graphql.Null { invalids++ } case "createEmailSubscription": - out.Values[i] = ec._Mutation_createEmailSubscription(ctx, field) + + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_createEmailSubscription(ctx, field) + }) + if out.Values[i] == graphql.Null { invalids++ } case "verifyEmailSubscription": - out.Values[i] = ec._Mutation_verifyEmailSubscription(ctx, field) + + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_verifyEmailSubscription(ctx, field) + }) + if out.Values[i] == graphql.Null { invalids++ } case "updateInvoiceRequest": - out.Values[i] = ec._Mutation_updateInvoiceRequest(ctx, field) + + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_updateInvoiceRequest(ctx, field) + }) + if out.Values[i] == graphql.Null { invalids++ } case "publishLocation": - out.Values[i] = ec._Mutation_publishLocation(ctx, field) + + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_publishLocation(ctx, field) + }) + if out.Values[i] == graphql.Null { invalids++ } case "createReferral": - out.Values[i] = ec._Mutation_createReferral(ctx, field) + + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_createReferral(ctx, field) + }) + if out.Values[i] == graphql.Null { invalids++ } case "createUser": - out.Values[i] = ec._Mutation_createUser(ctx, field) + + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_createUser(ctx, field) + }) + if out.Values[i] == graphql.Null { invalids++ } case "updateUser": - out.Values[i] = ec._Mutation_updateUser(ctx, field) + + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Mutation_updateUser(ctx, field) + }) + if out.Values[i] == graphql.Null { invalids++ } @@ -15581,7 +19784,6 @@ var nodeImplementors = []string{"Node"} func (ec *executionContext) _Node(ctx context.Context, sel ast.SelectionSet, obj *db.Node) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, nodeImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -15589,13 +19791,16 @@ func (ec *executionContext) _Node(ctx context.Context, sel ast.SelectionSet, obj case "__typename": out.Values[i] = graphql.MarshalString("Node") case "pubkey": + out.Values[i] = ec._Node_pubkey(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "addr": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15606,9 +19811,16 @@ func (ec *executionContext) _Node(ctx context.Context, sel ast.SelectionSet, obj atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "alias": + out.Values[i] = ec._Node_alias(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } @@ -15627,7 +19839,6 @@ var openingTimeImplementors = []string{"OpeningTime"} func (ec *executionContext) _OpeningTime(ctx context.Context, sel ast.SelectionSet, obj *db.OpeningTime) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, openingTimeImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -15636,7 +19847,8 @@ func (ec *executionContext) _OpeningTime(ctx context.Context, sel ast.SelectionS out.Values[i] = graphql.MarshalString("OpeningTime") case "regularHours": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15647,15 +19859,23 @@ func (ec *executionContext) _OpeningTime(ctx context.Context, sel ast.SelectionS atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "twentyfourseven": + out.Values[i] = ec._OpeningTime_twentyfourseven(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "exceptionalOpenings": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15666,10 +19886,16 @@ func (ec *executionContext) _OpeningTime(ctx context.Context, sel ast.SelectionS atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "exceptionalClosings": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15680,6 +19906,11 @@ func (ec *executionContext) _OpeningTime(ctx context.Context, sel ast.SelectionS atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) default: panic("unknown field " + strconv.Quote(field.Name)) @@ -15696,7 +19927,6 @@ var priceComponentImplementors = []string{"PriceComponent"} func (ec *executionContext) _PriceComponent(ctx context.Context, sel ast.SelectionSet, obj *db.PriceComponent) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, priceComponentImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -15705,7 +19935,8 @@ func (ec *executionContext) _PriceComponent(ctx context.Context, sel ast.Selecti out.Values[i] = graphql.MarshalString("PriceComponent") case "type": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15716,15 +19947,23 @@ func (ec *executionContext) _PriceComponent(ctx context.Context, sel ast.Selecti atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "price": + out.Values[i] = ec._PriceComponent_price(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "priceMsat": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15735,10 +19974,16 @@ func (ec *executionContext) _PriceComponent(ctx context.Context, sel ast.Selecti atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "commissionMsat": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15749,10 +19994,16 @@ func (ec *executionContext) _PriceComponent(ctx context.Context, sel ast.Selecti atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "taxMsat": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15760,9 +20011,16 @@ func (ec *executionContext) _PriceComponent(ctx context.Context, sel ast.Selecti }() res = ec._PriceComponent_taxMsat(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "stepSize": + out.Values[i] = ec._PriceComponent_stepSize(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } @@ -15781,7 +20039,6 @@ var promotionImplementors = []string{"Promotion"} func (ec *executionContext) _Promotion(ctx context.Context, sel ast.SelectionSet, obj *db.Promotion) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, promotionImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -15789,12 +20046,16 @@ func (ec *executionContext) _Promotion(ctx context.Context, sel ast.SelectionSet case "__typename": out.Values[i] = graphql.MarshalString("Promotion") case "code": + out.Values[i] = ec._Promotion_code(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "description": + out.Values[i] = ec._Promotion_description(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } @@ -15813,7 +20074,6 @@ var queryImplementors = []string{"Query"} func (ec *executionContext) _Query(ctx context.Context, sel ast.SelectionSet) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, queryImplementors) - ctx = graphql.WithFieldContext(ctx, &graphql.FieldContext{ Object: "Query", }) @@ -15821,12 +20081,18 @@ func (ec *executionContext) _Query(ctx context.Context, sel ast.SelectionSet) gr out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { + innerCtx := graphql.WithRootFieldContext(ctx, &graphql.RootFieldContext{ + Object: field.Name, + Field: field, + }) + switch field.Name { case "__typename": out.Values[i] = graphql.MarshalString("Query") case "verifyAuthentication": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15837,10 +20103,19 @@ func (ec *executionContext) _Query(ctx context.Context, sel ast.SelectionSet) gr atomic.AddUint32(&invalids, 1) } return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) + } + + out.Concurrently(i, func() graphql.Marshaler { + return rrm(innerCtx) }) case "listInvoiceRequests": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15851,10 +20126,19 @@ func (ec *executionContext) _Query(ctx context.Context, sel ast.SelectionSet) gr atomic.AddUint32(&invalids, 1) } return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) + } + + out.Concurrently(i, func() graphql.Marshaler { + return rrm(innerCtx) }) case "getLocation": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15865,10 +20149,19 @@ func (ec *executionContext) _Query(ctx context.Context, sel ast.SelectionSet) gr atomic.AddUint32(&invalids, 1) } return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) + } + + out.Concurrently(i, func() graphql.Marshaler { + return rrm(innerCtx) }) case "listLocations": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15879,10 +20172,19 @@ func (ec *executionContext) _Query(ctx context.Context, sel ast.SelectionSet) gr atomic.AddUint32(&invalids, 1) } return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) + } + + out.Concurrently(i, func() graphql.Marshaler { + return rrm(innerCtx) }) case "getRate": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15890,10 +20192,19 @@ func (ec *executionContext) _Query(ctx context.Context, sel ast.SelectionSet) gr }() res = ec._Query_getRate(ctx, field) return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) + } + + out.Concurrently(i, func() graphql.Marshaler { + return rrm(innerCtx) }) case "getSession": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15904,10 +20215,19 @@ func (ec *executionContext) _Query(ctx context.Context, sel ast.SelectionSet) gr atomic.AddUint32(&invalids, 1) } return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) + } + + out.Concurrently(i, func() graphql.Marshaler { + return rrm(innerCtx) }) case "getSessionInvoice": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15915,10 +20235,19 @@ func (ec *executionContext) _Query(ctx context.Context, sel ast.SelectionSet) gr }() res = ec._Query_getSessionInvoice(ctx, field) return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) + } + + out.Concurrently(i, func() graphql.Marshaler { + return rrm(innerCtx) }) case "getTariff": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15929,10 +20258,19 @@ func (ec *executionContext) _Query(ctx context.Context, sel ast.SelectionSet) gr atomic.AddUint32(&invalids, 1) } return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) + } + + out.Concurrently(i, func() graphql.Marshaler { + return rrm(innerCtx) }) case "getUser": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -15943,11 +20281,27 @@ func (ec *executionContext) _Query(ctx context.Context, sel ast.SelectionSet) gr atomic.AddUint32(&invalids, 1) } return res + } + + rrm := func(ctx context.Context) graphql.Marshaler { + return ec.OperationContext.RootResolverMiddleware(ctx, innerFunc) + } + + out.Concurrently(i, func() graphql.Marshaler { + return rrm(innerCtx) }) case "__type": - out.Values[i] = ec._Query___type(ctx, field) + + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Query___type(ctx, field) + }) + case "__schema": - out.Values[i] = ec._Query___schema(ctx, field) + + out.Values[i] = ec.OperationContext.RootResolverMiddleware(innerCtx, func(ctx context.Context) (res graphql.Marshaler) { + return ec._Query___schema(ctx, field) + }) + default: panic("unknown field " + strconv.Quote(field.Name)) } @@ -15963,7 +20317,6 @@ var rateImplementors = []string{"Rate"} func (ec *executionContext) _Rate(ctx context.Context, sel ast.SelectionSet, obj *Rate) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, rateImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -15971,17 +20324,23 @@ func (ec *executionContext) _Rate(ctx context.Context, sel ast.SelectionSet, obj case "__typename": out.Values[i] = graphql.MarshalString("Rate") case "rate": + out.Values[i] = ec._Rate_rate(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "rateMsat": + out.Values[i] = ec._Rate_rateMsat(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "lastUpdated": + out.Values[i] = ec._Rate_lastUpdated(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } @@ -16000,7 +20359,6 @@ var regularHourImplementors = []string{"RegularHour"} func (ec *executionContext) _RegularHour(ctx context.Context, sel ast.SelectionSet, obj *db.RegularHour) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, regularHourImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -16009,7 +20367,8 @@ func (ec *executionContext) _RegularHour(ctx context.Context, sel ast.SelectionS out.Values[i] = graphql.MarshalString("RegularHour") case "weekday": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16020,14 +20379,23 @@ func (ec *executionContext) _RegularHour(ctx context.Context, sel ast.SelectionS atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "periodBegin": + out.Values[i] = ec._RegularHour_periodBegin(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "periodEnd": + out.Values[i] = ec._RegularHour_periodEnd(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } @@ -16046,7 +20414,6 @@ var resultIdImplementors = []string{"ResultId"} func (ec *executionContext) _ResultId(ctx context.Context, sel ast.SelectionSet, obj *ResultID) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, resultIdImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -16054,7 +20421,9 @@ func (ec *executionContext) _ResultId(ctx context.Context, sel ast.SelectionSet, case "__typename": out.Values[i] = graphql.MarshalString("ResultId") case "id": + out.Values[i] = ec._ResultId_id(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } @@ -16073,7 +20442,6 @@ var resultOkImplementors = []string{"ResultOk"} func (ec *executionContext) _ResultOk(ctx context.Context, sel ast.SelectionSet, obj *ResultOk) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, resultOkImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -16081,7 +20449,9 @@ func (ec *executionContext) _ResultOk(ctx context.Context, sel ast.SelectionSet, case "__typename": out.Values[i] = graphql.MarshalString("ResultOk") case "ok": + out.Values[i] = ec._ResultOk_ok(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } @@ -16100,7 +20470,6 @@ var sessionImplementors = []string{"Session"} func (ec *executionContext) _Session(ctx context.Context, sel ast.SelectionSet, obj *db.Session) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, sessionImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -16108,18 +20477,23 @@ func (ec *executionContext) _Session(ctx context.Context, sel ast.SelectionSet, case "__typename": out.Values[i] = graphql.MarshalString("Session") case "id": + out.Values[i] = ec._Session_id(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "uid": + out.Values[i] = ec._Session_uid(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "authorizationId": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16127,10 +20501,16 @@ func (ec *executionContext) _Session(ctx context.Context, sel ast.SelectionSet, }() res = ec._Session_authorizationId(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "startDatetime": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16141,10 +20521,16 @@ func (ec *executionContext) _Session(ctx context.Context, sel ast.SelectionSet, atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "endDatetime": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16152,15 +20538,23 @@ func (ec *executionContext) _Session(ctx context.Context, sel ast.SelectionSet, }() res = ec._Session_endDatetime(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "kwh": + out.Values[i] = ec._Session_kwh(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "authMethod": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16171,10 +20565,16 @@ func (ec *executionContext) _Session(ctx context.Context, sel ast.SelectionSet, atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "location": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16185,10 +20585,16 @@ func (ec *executionContext) _Session(ctx context.Context, sel ast.SelectionSet, atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "evse": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16199,10 +20605,16 @@ func (ec *executionContext) _Session(ctx context.Context, sel ast.SelectionSet, atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "connector": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16213,10 +20625,16 @@ func (ec *executionContext) _Session(ctx context.Context, sel ast.SelectionSet, atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "meterId": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16224,10 +20642,16 @@ func (ec *executionContext) _Session(ctx context.Context, sel ast.SelectionSet, }() res = ec._Session_meterId(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "sessionInvoices": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16238,10 +20662,16 @@ func (ec *executionContext) _Session(ctx context.Context, sel ast.SelectionSet, atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "status": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16252,10 +20682,16 @@ func (ec *executionContext) _Session(ctx context.Context, sel ast.SelectionSet, atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "lastUpdated": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16266,6 +20702,11 @@ func (ec *executionContext) _Session(ctx context.Context, sel ast.SelectionSet, atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) default: panic("unknown field " + strconv.Quote(field.Name)) @@ -16282,7 +20723,6 @@ var sessionInvoiceImplementors = []string{"SessionInvoice"} func (ec *executionContext) _SessionInvoice(ctx context.Context, sel ast.SelectionSet, obj *db.SessionInvoice) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, sessionInvoiceImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -16290,73 +20730,100 @@ func (ec *executionContext) _SessionInvoice(ctx context.Context, sel ast.Selecti case "__typename": out.Values[i] = graphql.MarshalString("SessionInvoice") case "id": + out.Values[i] = ec._SessionInvoice_id(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "currency": + out.Values[i] = ec._SessionInvoice_currency(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "currencyRate": + out.Values[i] = ec._SessionInvoice_currencyRate(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "currencyRateMsat": + out.Values[i] = ec._SessionInvoice_currencyRateMsat(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "priceFiat": + out.Values[i] = ec._SessionInvoice_priceFiat(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "priceMsat": + out.Values[i] = ec._SessionInvoice_priceMsat(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "commissionFiat": + out.Values[i] = ec._SessionInvoice_commissionFiat(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "commissionMsat": + out.Values[i] = ec._SessionInvoice_commissionMsat(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "taxFiat": + out.Values[i] = ec._SessionInvoice_taxFiat(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "taxMsat": + out.Values[i] = ec._SessionInvoice_taxMsat(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "totalFiat": + out.Values[i] = ec._SessionInvoice_totalFiat(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "totalMsat": + out.Values[i] = ec._SessionInvoice_totalMsat(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "paymentRequest": + out.Values[i] = ec._SessionInvoice_paymentRequest(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "signature": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16367,20 +20834,30 @@ func (ec *executionContext) _SessionInvoice(ctx context.Context, sel ast.Selecti atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "isSettled": + out.Values[i] = ec._SessionInvoice_isSettled(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "isExpired": + out.Values[i] = ec._SessionInvoice_isExpired(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "lastUpdated": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16391,6 +20868,11 @@ func (ec *executionContext) _SessionInvoice(ctx context.Context, sel ast.Selecti atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) default: panic("unknown field " + strconv.Quote(field.Name)) @@ -16407,7 +20889,6 @@ var startSessionImplementors = []string{"StartSession"} func (ec *executionContext) _StartSession(ctx context.Context, sel ast.SelectionSet, obj *StartSession) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, startSessionImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -16415,32 +20896,44 @@ func (ec *executionContext) _StartSession(ctx context.Context, sel ast.Selection case "__typename": out.Values[i] = graphql.MarshalString("StartSession") case "id": + out.Values[i] = ec._StartSession_id(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "status": + out.Values[i] = ec._StartSession_status(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "authorizationId": + out.Values[i] = ec._StartSession_authorizationId(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "verificationKey": + out.Values[i] = ec._StartSession_verificationKey(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "locationUid": + out.Values[i] = ec._StartSession_locationUid(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "evseUid": + out.Values[i] = ec._StartSession_evseUid(ctx, field, obj) + default: panic("unknown field " + strconv.Quote(field.Name)) } @@ -16456,7 +20949,6 @@ var statusScheduleImplementors = []string{"StatusSchedule"} func (ec *executionContext) _StatusSchedule(ctx context.Context, sel ast.SelectionSet, obj *db.StatusSchedule) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, statusScheduleImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -16465,7 +20957,8 @@ func (ec *executionContext) _StatusSchedule(ctx context.Context, sel ast.Selecti out.Values[i] = graphql.MarshalString("StatusSchedule") case "periodBegin": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16476,10 +20969,16 @@ func (ec *executionContext) _StatusSchedule(ctx context.Context, sel ast.Selecti atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "periodEnd": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16487,10 +20986,16 @@ func (ec *executionContext) _StatusSchedule(ctx context.Context, sel ast.Selecti }() res = ec._StatusSchedule_periodEnd(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "status": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16501,6 +21006,11 @@ func (ec *executionContext) _StatusSchedule(ctx context.Context, sel ast.Selecti atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) default: panic("unknown field " + strconv.Quote(field.Name)) @@ -16517,7 +21027,6 @@ var stopSessionImplementors = []string{"StopSession"} func (ec *executionContext) _StopSession(ctx context.Context, sel ast.SelectionSet, obj *StopSession) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, stopSessionImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -16525,17 +21034,23 @@ func (ec *executionContext) _StopSession(ctx context.Context, sel ast.SelectionS case "__typename": out.Values[i] = graphql.MarshalString("StopSession") case "id": + out.Values[i] = ec._StopSession_id(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "status": + out.Values[i] = ec._StopSession_status(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "sessionUid": + out.Values[i] = ec._StopSession_sessionUid(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } @@ -16554,7 +21069,6 @@ var tariffImplementors = []string{"Tariff"} func (ec *executionContext) _Tariff(ctx context.Context, sel ast.SelectionSet, obj *db.Tariff) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, tariffImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -16562,23 +21076,30 @@ func (ec *executionContext) _Tariff(ctx context.Context, sel ast.SelectionSet, o case "__typename": out.Values[i] = graphql.MarshalString("Tariff") case "id": + out.Values[i] = ec._Tariff_id(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "uid": + out.Values[i] = ec._Tariff_uid(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "currency": + out.Values[i] = ec._Tariff_currency(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "currencyRate": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16589,10 +21110,16 @@ func (ec *executionContext) _Tariff(ctx context.Context, sel ast.SelectionSet, o atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "currencyRateMsat": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16603,10 +21130,16 @@ func (ec *executionContext) _Tariff(ctx context.Context, sel ast.SelectionSet, o atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "commissionPercent": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16617,10 +21150,16 @@ func (ec *executionContext) _Tariff(ctx context.Context, sel ast.SelectionSet, o atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "taxPercent": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16628,10 +21167,16 @@ func (ec *executionContext) _Tariff(ctx context.Context, sel ast.SelectionSet, o }() res = ec._Tariff_taxPercent(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "elements": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16642,10 +21187,16 @@ func (ec *executionContext) _Tariff(ctx context.Context, sel ast.SelectionSet, o atomic.AddUint32(&invalids, 1) } return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) case "energyMix": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16653,6 +21204,11 @@ func (ec *executionContext) _Tariff(ctx context.Context, sel ast.SelectionSet, o }() res = ec._Tariff_energyMix(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) default: panic("unknown field " + strconv.Quote(field.Name)) @@ -16669,7 +21225,6 @@ var tariffElementImplementors = []string{"TariffElement"} func (ec *executionContext) _TariffElement(ctx context.Context, sel ast.SelectionSet, obj *TariffElement) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, tariffElementImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -16677,9 +21232,13 @@ func (ec *executionContext) _TariffElement(ctx context.Context, sel ast.Selectio case "__typename": out.Values[i] = graphql.MarshalString("TariffElement") case "priceComponents": + out.Values[i] = ec._TariffElement_priceComponents(ctx, field, obj) + case "restrictions": + out.Values[i] = ec._TariffElement_restrictions(ctx, field, obj) + default: panic("unknown field " + strconv.Quote(field.Name)) } @@ -16695,7 +21254,6 @@ var textDescriptionImplementors = []string{"TextDescription"} func (ec *executionContext) _TextDescription(ctx context.Context, sel ast.SelectionSet, obj *TextDescription) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, textDescriptionImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -16703,12 +21261,16 @@ func (ec *executionContext) _TextDescription(ctx context.Context, sel ast.Select case "__typename": out.Values[i] = graphql.MarshalString("TextDescription") case "text": + out.Values[i] = ec._TextDescription_text(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "description": + out.Values[i] = ec._TextDescription_description(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } @@ -16727,7 +21289,6 @@ var userImplementors = []string{"User"} func (ec *executionContext) _User(ctx context.Context, sel ast.SelectionSet, obj *db.User) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, userImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -16735,23 +21296,30 @@ func (ec *executionContext) _User(ctx context.Context, sel ast.SelectionSet, obj case "__typename": out.Values[i] = graphql.MarshalString("User") case "id": + out.Values[i] = ec._User_id(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "pubkey": + out.Values[i] = ec._User_pubkey(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "deviceToken": + out.Values[i] = ec._User_deviceToken(ctx, field, obj) + if out.Values[i] == graphql.Null { atomic.AddUint32(&invalids, 1) } case "referralCode": field := field - out.Concurrently(i, func() (res graphql.Marshaler) { + + innerFunc := func(ctx context.Context) (res graphql.Marshaler) { defer func() { if r := recover(); r != nil { ec.Error(ctx, ec.Recover(ctx, r)) @@ -16759,6 +21327,11 @@ func (ec *executionContext) _User(ctx context.Context, sel ast.SelectionSet, obj }() res = ec._User_referralCode(ctx, field, obj) return res + } + + out.Concurrently(i, func() graphql.Marshaler { + return innerFunc(ctx) + }) default: panic("unknown field " + strconv.Quote(field.Name)) @@ -16775,7 +21348,6 @@ var verifyAuthenticationImplementors = []string{"VerifyAuthentication"} func (ec *executionContext) _VerifyAuthentication(ctx context.Context, sel ast.SelectionSet, obj *VerifyAuthentication) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, verifyAuthenticationImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -16783,7 +21355,9 @@ func (ec *executionContext) _VerifyAuthentication(ctx context.Context, sel ast.S case "__typename": out.Values[i] = graphql.MarshalString("VerifyAuthentication") case "verified": + out.Values[i] = ec._VerifyAuthentication_verified(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } @@ -16802,7 +21376,6 @@ var __DirectiveImplementors = []string{"__Directive"} func (ec *executionContext) ___Directive(ctx context.Context, sel ast.SelectionSet, obj *introspection.Directive) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, __DirectiveImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -16810,24 +21383,34 @@ func (ec *executionContext) ___Directive(ctx context.Context, sel ast.SelectionS case "__typename": out.Values[i] = graphql.MarshalString("__Directive") case "name": + out.Values[i] = ec.___Directive_name(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "description": + out.Values[i] = ec.___Directive_description(ctx, field, obj) + case "locations": + out.Values[i] = ec.___Directive_locations(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "args": + out.Values[i] = ec.___Directive_args(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "isRepeatable": + out.Values[i] = ec.___Directive_isRepeatable(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } @@ -16846,7 +21429,6 @@ var __EnumValueImplementors = []string{"__EnumValue"} func (ec *executionContext) ___EnumValue(ctx context.Context, sel ast.SelectionSet, obj *introspection.EnumValue) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, __EnumValueImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -16854,19 +21436,27 @@ func (ec *executionContext) ___EnumValue(ctx context.Context, sel ast.SelectionS case "__typename": out.Values[i] = graphql.MarshalString("__EnumValue") case "name": + out.Values[i] = ec.___EnumValue_name(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "description": + out.Values[i] = ec.___EnumValue_description(ctx, field, obj) + case "isDeprecated": + out.Values[i] = ec.___EnumValue_isDeprecated(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "deprecationReason": + out.Values[i] = ec.___EnumValue_deprecationReason(ctx, field, obj) + default: panic("unknown field " + strconv.Quote(field.Name)) } @@ -16882,7 +21472,6 @@ var __FieldImplementors = []string{"__Field"} func (ec *executionContext) ___Field(ctx context.Context, sel ast.SelectionSet, obj *introspection.Field) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, __FieldImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -16890,29 +21479,41 @@ func (ec *executionContext) ___Field(ctx context.Context, sel ast.SelectionSet, case "__typename": out.Values[i] = graphql.MarshalString("__Field") case "name": + out.Values[i] = ec.___Field_name(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "description": + out.Values[i] = ec.___Field_description(ctx, field, obj) + case "args": + out.Values[i] = ec.___Field_args(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "type": + out.Values[i] = ec.___Field_type(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "isDeprecated": + out.Values[i] = ec.___Field_isDeprecated(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "deprecationReason": + out.Values[i] = ec.___Field_deprecationReason(ctx, field, obj) + default: panic("unknown field " + strconv.Quote(field.Name)) } @@ -16928,7 +21529,6 @@ var __InputValueImplementors = []string{"__InputValue"} func (ec *executionContext) ___InputValue(ctx context.Context, sel ast.SelectionSet, obj *introspection.InputValue) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, __InputValueImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -16936,19 +21536,27 @@ func (ec *executionContext) ___InputValue(ctx context.Context, sel ast.Selection case "__typename": out.Values[i] = graphql.MarshalString("__InputValue") case "name": + out.Values[i] = ec.___InputValue_name(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "description": + out.Values[i] = ec.___InputValue_description(ctx, field, obj) + case "type": + out.Values[i] = ec.___InputValue_type(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "defaultValue": + out.Values[i] = ec.___InputValue_defaultValue(ctx, field, obj) + default: panic("unknown field " + strconv.Quote(field.Name)) } @@ -16964,29 +21572,42 @@ var __SchemaImplementors = []string{"__Schema"} func (ec *executionContext) ___Schema(ctx context.Context, sel ast.SelectionSet, obj *introspection.Schema) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, __SchemaImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { switch field.Name { case "__typename": out.Values[i] = graphql.MarshalString("__Schema") + case "description": + + out.Values[i] = ec.___Schema_description(ctx, field, obj) + case "types": + out.Values[i] = ec.___Schema_types(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "queryType": + out.Values[i] = ec.___Schema_queryType(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "mutationType": + out.Values[i] = ec.___Schema_mutationType(ctx, field, obj) + case "subscriptionType": + out.Values[i] = ec.___Schema_subscriptionType(ctx, field, obj) + case "directives": + out.Values[i] = ec.___Schema_directives(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } @@ -17005,7 +21626,6 @@ var __TypeImplementors = []string{"__Type"} func (ec *executionContext) ___Type(ctx context.Context, sel ast.SelectionSet, obj *introspection.Type) graphql.Marshaler { fields := graphql.CollectFields(ec.OperationContext, sel, __TypeImplementors) - out := graphql.NewFieldSet(fields) var invalids uint32 for i, field := range fields { @@ -17013,26 +21633,48 @@ func (ec *executionContext) ___Type(ctx context.Context, sel ast.SelectionSet, o case "__typename": out.Values[i] = graphql.MarshalString("__Type") case "kind": + out.Values[i] = ec.___Type_kind(ctx, field, obj) + if out.Values[i] == graphql.Null { invalids++ } case "name": + out.Values[i] = ec.___Type_name(ctx, field, obj) + case "description": + out.Values[i] = ec.___Type_description(ctx, field, obj) + case "fields": + out.Values[i] = ec.___Type_fields(ctx, field, obj) + case "interfaces": + out.Values[i] = ec.___Type_interfaces(ctx, field, obj) + case "possibleTypes": + out.Values[i] = ec.___Type_possibleTypes(ctx, field, obj) + case "enumValues": + out.Values[i] = ec.___Type_enumValues(ctx, field, obj) + case "inputFields": + out.Values[i] = ec.___Type_inputFields(ctx, field, obj) + case "ofType": + out.Values[i] = ec.___Type_ofType(ctx, field, obj) + + case "specifiedByURL": + + out.Values[i] = ec.___Type_specifiedByURL(ctx, field, obj) + default: panic("unknown field " + strconv.Quote(field.Name)) } @@ -17115,7 +21757,7 @@ func (ec *executionContext) marshalNBoolean2bool(ctx context.Context, sel ast.Se res := graphql.MarshalBoolean(v) if res == graphql.Null { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } } return res @@ -17128,7 +21770,7 @@ func (ec *executionContext) marshalNChannelRequest2githubᚗcomᚋsatimotoᚋgo func (ec *executionContext) marshalNChannelRequest2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐChannelRequest(ctx context.Context, sel ast.SelectionSet, v *db.ChannelRequest) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } return graphql.Null } @@ -17186,7 +21828,7 @@ func (ec *executionContext) marshalNConnector2ᚕgithubᚗcomᚋsatimotoᚋgoᚑ func (ec *executionContext) marshalNConnector2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐConnector(ctx context.Context, sel ast.SelectionSet, v *db.Connector) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } return graphql.Null } @@ -17200,7 +21842,7 @@ func (ec *executionContext) marshalNCreateAuthentication2githubᚗcomᚋsatimoto func (ec *executionContext) marshalNCreateAuthentication2ᚖgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐCreateAuthentication(ctx context.Context, sel ast.SelectionSet, v *CreateAuthentication) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } return graphql.Null } @@ -17244,7 +21886,7 @@ func (ec *executionContext) marshalNCredential2githubᚗcomᚋsatimotoᚋgoᚑda func (ec *executionContext) marshalNCredential2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐCredential(ctx context.Context, sel ast.SelectionSet, v *db.Credential) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } return graphql.Null } @@ -17306,7 +21948,7 @@ func (ec *executionContext) marshalNEmailSubscription2githubᚗcomᚋsatimotoᚋ func (ec *executionContext) marshalNEmailSubscription2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐEmailSubscription(ctx context.Context, sel ast.SelectionSet, v *db.EmailSubscription) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } return graphql.Null } @@ -17460,7 +22102,7 @@ func (ec *executionContext) marshalNEvse2ᚕgithubᚗcomᚋsatimotoᚋgoᚑdatas func (ec *executionContext) marshalNEvse2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐEvse(ctx context.Context, sel ast.SelectionSet, v *db.Evse) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } return graphql.Null } @@ -17522,7 +22164,7 @@ func (ec *executionContext) marshalNExchangeAuthentication2githubᚗcomᚋsatimo func (ec *executionContext) marshalNExchangeAuthentication2ᚖgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐExchangeAuthentication(ctx context.Context, sel ast.SelectionSet, v *ExchangeAuthentication) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } return graphql.Null } @@ -17530,18 +22172,18 @@ func (ec *executionContext) marshalNExchangeAuthentication2ᚖgithubᚗcomᚋsat } func (ec *executionContext) unmarshalNFloat2float64(ctx context.Context, v interface{}) (float64, error) { - res, err := graphql.UnmarshalFloat(v) + res, err := graphql.UnmarshalFloatContext(ctx, v) return res, graphql.ErrorOnPath(ctx, err) } func (ec *executionContext) marshalNFloat2float64(ctx context.Context, sel ast.SelectionSet, v float64) graphql.Marshaler { - res := graphql.MarshalFloat(v) + res := graphql.MarshalFloatContext(v) if res == graphql.Null { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } } - return res + return graphql.WrapContextMarshaler(ctx, res) } func (ec *executionContext) unmarshalNGeometry2githubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋgeomᚐGeometry4326(ctx context.Context, v interface{}) (geom.Geometry4326, error) { @@ -17553,7 +22195,7 @@ func (ec *executionContext) marshalNGeometry2githubᚗcomᚋsatimotoᚋgoᚑdata res := geom.MarshalGeometry4326(v) if res == graphql.Null { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } } return res @@ -17583,7 +22225,7 @@ func (ec *executionContext) marshalNID2int64(ctx context.Context, sel ast.Select res := graphql.MarshalInt64(v) if res == graphql.Null { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } } return res @@ -17646,7 +22288,7 @@ func (ec *executionContext) marshalNInt2int(ctx context.Context, sel ast.Selecti res := graphql.MarshalInt(v) if res == graphql.Null { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } } return res @@ -17661,7 +22303,7 @@ func (ec *executionContext) marshalNInt2int32(ctx context.Context, sel ast.Selec res := graphql.MarshalInt32(v) if res == graphql.Null { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } } return res @@ -17676,7 +22318,7 @@ func (ec *executionContext) marshalNInt2int64(ctx context.Context, sel ast.Selec res := graphql.MarshalInt64(v) if res == graphql.Null { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } } return res @@ -17733,7 +22375,7 @@ func (ec *executionContext) marshalNInvoiceRequest2ᚕgithubᚗcomᚋsatimotoᚋ func (ec *executionContext) marshalNInvoiceRequest2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐInvoiceRequest(ctx context.Context, sel ast.SelectionSet, v *db.InvoiceRequest) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } return graphql.Null } @@ -17800,7 +22442,7 @@ func (ec *executionContext) marshalNLocation2githubᚗcomᚋsatimotoᚋgoᚑdata func (ec *executionContext) marshalNLocation2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐLocation(ctx context.Context, sel ast.SelectionSet, v *db.Location) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } return graphql.Null } @@ -17814,7 +22456,7 @@ func (ec *executionContext) marshalNNode2githubᚗcomᚋsatimotoᚋgoᚑdatastor func (ec *executionContext) marshalNNode2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐNode(ctx context.Context, sel ast.SelectionSet, v *db.Node) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } return graphql.Null } @@ -17832,7 +22474,7 @@ func (ec *executionContext) marshalNPromotion2githubᚗcomᚋsatimotoᚋgoᚑdat func (ec *executionContext) marshalNPromotion2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐPromotion(ctx context.Context, sel ast.SelectionSet, v *db.Promotion) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } return graphql.Null } @@ -17904,7 +22546,7 @@ func (ec *executionContext) marshalNResultId2githubᚗcomᚋsatimotoᚋgoᚑapi func (ec *executionContext) marshalNResultId2ᚖgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐResultID(ctx context.Context, sel ast.SelectionSet, v *ResultID) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } return graphql.Null } @@ -17918,7 +22560,7 @@ func (ec *executionContext) marshalNResultOk2githubᚗcomᚋsatimotoᚋgoᚑapi func (ec *executionContext) marshalNResultOk2ᚖgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐResultOk(ctx context.Context, sel ast.SelectionSet, v *ResultOk) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } return graphql.Null } @@ -17932,7 +22574,7 @@ func (ec *executionContext) marshalNSession2githubᚗcomᚋsatimotoᚋgoᚑdatas func (ec *executionContext) marshalNSession2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐSession(ctx context.Context, sel ast.SelectionSet, v *db.Session) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } return graphql.Null } @@ -17994,7 +22636,7 @@ func (ec *executionContext) marshalNStartSession2githubᚗcomᚋsatimotoᚋgoᚑ func (ec *executionContext) marshalNStartSession2ᚖgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐStartSession(ctx context.Context, sel ast.SelectionSet, v *StartSession) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } return graphql.Null } @@ -18061,7 +22703,7 @@ func (ec *executionContext) marshalNStopSession2githubᚗcomᚋsatimotoᚋgoᚑa func (ec *executionContext) marshalNStopSession2ᚖgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐStopSession(ctx context.Context, sel ast.SelectionSet, v *StopSession) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } return graphql.Null } @@ -18082,12 +22724,17 @@ func (ec *executionContext) marshalNString2string(ctx context.Context, sel ast.S res := graphql.MarshalString(v) if res == graphql.Null { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } } return res } +func (ec *executionContext) unmarshalNSyncCredentialInput2githubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐSyncCredentialInput(ctx context.Context, v interface{}) (SyncCredentialInput, error) { + res, err := ec.unmarshalInputSyncCredentialInput(ctx, v) + return res, graphql.ErrorOnPath(ctx, err) +} + func (ec *executionContext) marshalNTariff2githubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐTariff(ctx context.Context, sel ast.SelectionSet, v db.Tariff) graphql.Marshaler { return ec._Tariff(ctx, sel, &v) } @@ -18095,7 +22742,7 @@ func (ec *executionContext) marshalNTariff2githubᚗcomᚋsatimotoᚋgoᚑdatast func (ec *executionContext) marshalNTariff2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐTariff(ctx context.Context, sel ast.SelectionSet, v *db.Tariff) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } return graphql.Null } @@ -18220,7 +22867,7 @@ func (ec *executionContext) marshalNUser2githubᚗcomᚋsatimotoᚋgoᚑdatastor func (ec *executionContext) marshalNUser2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐUser(ctx context.Context, sel ast.SelectionSet, v *db.User) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } return graphql.Null } @@ -18234,7 +22881,7 @@ func (ec *executionContext) marshalNVerifyAuthentication2githubᚗcomᚋsatimoto func (ec *executionContext) marshalNVerifyAuthentication2ᚖgithubᚗcomᚋsatimotoᚋgoᚑapiᚋgraphᚐVerifyAuthentication(ctx context.Context, sel ast.SelectionSet, v *VerifyAuthentication) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } return graphql.Null } @@ -18303,7 +22950,7 @@ func (ec *executionContext) marshalN__DirectiveLocation2string(ctx context.Conte res := graphql.MarshalString(v) if res == graphql.Null { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } } return res @@ -18312,11 +22959,7 @@ func (ec *executionContext) marshalN__DirectiveLocation2string(ctx context.Conte func (ec *executionContext) unmarshalN__DirectiveLocation2ᚕstringᚄ(ctx context.Context, v interface{}) ([]string, error) { var vSlice []interface{} if v != nil { - if tmp1, ok := v.([]interface{}); ok { - vSlice = tmp1 - } else { - vSlice = []interface{}{v} - } + vSlice = graphql.CoerceList(v) } var err error res := make([]string, len(vSlice)) @@ -18481,7 +23124,7 @@ func (ec *executionContext) marshalN__Type2ᚕgithubᚗcomᚋ99designsᚋgqlgen func (ec *executionContext) marshalN__Type2ᚖgithubᚗcomᚋ99designsᚋgqlgenᚋgraphqlᚋintrospectionᚐType(ctx context.Context, sel ast.SelectionSet, v *introspection.Type) graphql.Marshaler { if v == nil { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } return graphql.Null } @@ -18497,7 +23140,7 @@ func (ec *executionContext) marshalN__TypeKind2string(ctx context.Context, sel a res := graphql.MarshalString(v) if res == graphql.Null { if !graphql.HasFieldError(ctx, graphql.GetFieldContext(ctx)) { - ec.Errorf(ctx, "must not be null") + ec.Errorf(ctx, "the requested element is null which the schema does not allow") } } return res @@ -18509,7 +23152,8 @@ func (ec *executionContext) unmarshalOBoolean2bool(ctx context.Context, v interf } func (ec *executionContext) marshalOBoolean2bool(ctx context.Context, sel ast.SelectionSet, v bool) graphql.Marshaler { - return graphql.MarshalBoolean(v) + res := graphql.MarshalBoolean(v) + return res } func (ec *executionContext) unmarshalOBoolean2ᚖbool(ctx context.Context, v interface{}) (*bool, error) { @@ -18524,7 +23168,8 @@ func (ec *executionContext) marshalOBoolean2ᚖbool(ctx context.Context, sel ast if v == nil { return graphql.Null } - return graphql.MarshalBoolean(*v) + res := graphql.MarshalBoolean(*v) + return res } func (ec *executionContext) marshalOBusinessDetail2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐBusinessDetail(ctx context.Context, sel ast.SelectionSet, v *db.BusinessDetail) graphql.Marshaler { @@ -18567,7 +23212,7 @@ func (ec *executionContext) unmarshalOFloat2ᚖfloat64(ctx context.Context, v in if v == nil { return nil, nil } - res, err := graphql.UnmarshalFloat(v) + res, err := graphql.UnmarshalFloatContext(ctx, v) return &res, graphql.ErrorOnPath(ctx, err) } @@ -18575,7 +23220,8 @@ func (ec *executionContext) marshalOFloat2ᚖfloat64(ctx context.Context, sel as if v == nil { return graphql.Null } - return graphql.MarshalFloat(*v) + res := graphql.MarshalFloatContext(*v) + return graphql.WrapContextMarshaler(ctx, res) } func (ec *executionContext) unmarshalOGeometry2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋgeomᚐGeometry4326(ctx context.Context, v interface{}) (*geom.Geometry4326, error) { @@ -18590,7 +23236,8 @@ func (ec *executionContext) marshalOGeometry2ᚖgithubᚗcomᚋsatimotoᚋgoᚑd if v == nil { return graphql.Null } - return geom.MarshalGeometry4326(*v) + res := geom.MarshalGeometry4326(*v) + return res } func (ec *executionContext) unmarshalOID2ᚖint64(ctx context.Context, v interface{}) (*int64, error) { @@ -18605,7 +23252,8 @@ func (ec *executionContext) marshalOID2ᚖint64(ctx context.Context, sel ast.Sel if v == nil { return graphql.Null } - return graphql.MarshalInt64(*v) + res := graphql.MarshalInt64(*v) + return res } func (ec *executionContext) marshalOImage2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐImage(ctx context.Context, sel ast.SelectionSet, v *db.Image) graphql.Marshaler { @@ -18627,7 +23275,8 @@ func (ec *executionContext) marshalOInt2ᚖint(ctx context.Context, sel ast.Sele if v == nil { return graphql.Null } - return graphql.MarshalInt(*v) + res := graphql.MarshalInt(*v) + return res } func (ec *executionContext) marshalOOpeningTime2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐOpeningTime(ctx context.Context, sel ast.SelectionSet, v *db.OpeningTime) graphql.Marshaler { @@ -18704,11 +23353,7 @@ func (ec *executionContext) unmarshalOString2ᚕstringᚄ(ctx context.Context, v } var vSlice []interface{} if v != nil { - if tmp1, ok := v.([]interface{}); ok { - vSlice = tmp1 - } else { - vSlice = []interface{}{v} - } + vSlice = graphql.CoerceList(v) } var err error res := make([]string, len(vSlice)) @@ -18752,7 +23397,8 @@ func (ec *executionContext) marshalOString2ᚖstring(ctx context.Context, sel as if v == nil { return graphql.Null } - return graphql.MarshalString(*v) + res := graphql.MarshalString(*v) + return res } func (ec *executionContext) marshalOTariff2ᚖgithubᚗcomᚋsatimotoᚋgoᚑdatastoreᚋpkgᚋdbᚐTariff(ctx context.Context, sel ast.SelectionSet, v *db.Tariff) graphql.Marshaler { diff --git a/graph/model.go b/graph/model.go index 5b66175..3f42c8b 100644 --- a/graph/model.go +++ b/graph/model.go @@ -166,6 +166,13 @@ type StopSessionInput struct { SessionUID string `json:"sessionUid"` } +type SyncCredentialInput struct { + ID int64 `json:"id"` + FromDate *string `json:"fromDate"` + CountryCode *string `json:"countryCode"` + PartyID *string `json:"partyId"` +} + type TariffElement struct { PriceComponents []db.PriceComponent `json:"priceComponents"` Restrictions *db.ElementRestriction `json:"restrictions"` diff --git a/graph/resolver/authentication.go b/graph/resolver/authentication.go index 6f51ced..15e68f3 100644 --- a/graph/resolver/authentication.go +++ b/graph/resolver/authentication.go @@ -18,6 +18,7 @@ import ( "github.com/vektah/gqlparser/v2/gqlerror" ) +// CreateAuthentication is the resolver for the createAuthentication field. func (r *mutationResolver) CreateAuthentication(ctx context.Context, action graph.AuthenticationAction) (*graph.CreateAuthentication, error) { authentication, err := r.AuthenticationResolver.Repository.CreateAuthentication(ctx, db.CreateAuthenticationParams{ Action: db.AuthenticationActions(action), @@ -47,6 +48,7 @@ func (r *mutationResolver) CreateAuthentication(ctx context.Context, action grap }, nil } +// ExchangeAuthentication is the resolver for the exchangeAuthentication field. func (r *mutationResolver) ExchangeAuthentication(ctx context.Context, code string) (*graph.ExchangeAuthentication, error) { auth, err := r.AuthenticationResolver.Repository.GetAuthenticationByCode(ctx, code) @@ -83,6 +85,7 @@ func (r *mutationResolver) ExchangeAuthentication(ctx context.Context, code stri }, nil } +// VerifyAuthentication is the resolver for the verifyAuthentication field. func (r *queryResolver) VerifyAuthentication(ctx context.Context, code string) (*graph.VerifyAuthentication, error) { authentication, err := r.AuthenticationResolver.Repository.GetAuthenticationByCode(ctx, code) diff --git a/graph/resolver/businessdetail.go b/graph/resolver/businessdetail.go index 8cdd894..d880027 100644 --- a/graph/resolver/businessdetail.go +++ b/graph/resolver/businessdetail.go @@ -14,28 +14,12 @@ import ( "github.com/vektah/gqlparser/v2/gqlerror" ) -func (r *mutationResolver) CreateBusinessDetail(ctx context.Context, input graph.CreateBusinessDetailInput) (*db.BusinessDetail, error) { - params := param.NewCreateBusinessDetailParams(input) - - if input.Logo != nil { - if logo, err := r.CreateImage(ctx, *input.Logo); err == nil { - params.LogoID = dbUtil.SqlNullInt64(logo.ID) - } - } - - businessDetail, err := r.BusinessDetailRepository.CreateBusinessDetail(ctx, params) - - if err != nil { - return nil, gqlerror.Errorf("Error creating business detail") - } - - return &businessDetail, nil -} - +// Website is the resolver for the website field. func (r *businessDetailResolver) Website(ctx context.Context, obj *db.BusinessDetail) (*string, error) { return util.NullString(obj.Website) } +// Logo is the resolver for the logo field. func (r *businessDetailResolver) Logo(ctx context.Context, obj *db.BusinessDetail) (*db.Image, error) { if obj.LogoID.Valid { if image, err := r.ImageRepository.GetImage(ctx, obj.LogoID.Int64); err == nil { @@ -50,3 +34,27 @@ func (r *businessDetailResolver) Logo(ctx context.Context, obj *db.BusinessDetai func (r *Resolver) BusinessDetail() graph.BusinessDetailResolver { return &businessDetailResolver{r} } type businessDetailResolver struct{ *Resolver } + +// !!! WARNING !!! +// The code below was going to be deleted when updating resolvers. It has been copied here so you have +// one last chance to move it out of harms way if you want. There are two reasons this happens: +// - When renaming or deleting a resolver the old code will be put in here. You can safely delete +// it when you're done. +// - You have helper methods in this file. Move them out to keep these resolver files clean. +func (r *mutationResolver) CreateBusinessDetail(ctx context.Context, input graph.CreateBusinessDetailInput) (*db.BusinessDetail, error) { + params := param.NewCreateBusinessDetailParams(input) + + if input.Logo != nil { + if logo, err := r.CreateImage(ctx, *input.Logo); err == nil { + params.LogoID = dbUtil.SqlNullInt64(logo.ID) + } + } + + businessDetail, err := r.BusinessDetailRepository.CreateBusinessDetail(ctx, params) + + if err != nil { + return nil, gqlerror.Errorf("Error creating business detail") + } + + return &businessDetail, nil +} diff --git a/graph/resolver/channelrequest.go b/graph/resolver/channelrequest.go index 6dce9e9..a4c5f77 100644 --- a/graph/resolver/channelrequest.go +++ b/graph/resolver/channelrequest.go @@ -23,18 +23,22 @@ import ( "github.com/vektah/gqlparser/v2/gqlerror" ) +// PaymentHash is the resolver for the paymentHash field. func (r *channelRequestResolver) PaymentHash(ctx context.Context, obj *db.ChannelRequest) (string, error) { return base64.StdEncoding.EncodeToString(obj.PaymentHash), nil } +// PaymentAddr is the resolver for the paymentAddr field. func (r *channelRequestResolver) PaymentAddr(ctx context.Context, obj *db.ChannelRequest) (string, error) { return base64.StdEncoding.EncodeToString(obj.PaymentAddr), nil } +// AmountMsat is the resolver for the amountMsat field. func (r *channelRequestResolver) AmountMsat(ctx context.Context, obj *db.ChannelRequest) (string, error) { return strconv.FormatInt(obj.AmountMsat, 10), nil } +// Node is the resolver for the node field. func (r *channelRequestResolver) Node(ctx context.Context, obj *db.ChannelRequest) (*db.Node, error) { if node, err := r.NodeRepository.GetNode(ctx, obj.NodeID); err == nil { return &node, nil @@ -43,6 +47,7 @@ func (r *channelRequestResolver) Node(ctx context.Context, obj *db.ChannelReques return nil, gqlerror.Errorf("Node not found") } +// PendingChanID is the resolver for the pendingChanId field. func (r *channelRequestResolver) PendingChanID(ctx context.Context, obj *db.ChannelRequest) (string, error) { bigInt := new(big.Int) bigInt.SetBytes(obj.PendingChanID) @@ -50,24 +55,14 @@ func (r *channelRequestResolver) PendingChanID(ctx context.Context, obj *db.Chan return bigInt.Text(10), nil } +// Scid is the resolver for the scid field. func (r *channelRequestResolver) Scid(ctx context.Context, obj *db.ChannelRequest) (string, error) { scid := binary.LittleEndian.Uint64(obj.Scid) return strconv.FormatUint(scid, 10), nil } -func (r *channelRequestResolver) FeeBaseMsat(ctx context.Context, obj *db.ChannelRequest) (int, error) { - return int(obj.FeeBaseMsat), nil -} - -func (r *channelRequestResolver) FeeProportionalMillionths(ctx context.Context, obj *db.ChannelRequest) (int, error) { - return int(obj.FeeProportionalMillionths), nil -} - -func (r *channelRequestResolver) CltvExpiryDelta(ctx context.Context, obj *db.ChannelRequest) (int, error) { - return int(obj.CltvExpiryDelta), nil -} - +// CreateChannelRequest is the resolver for the createChannelRequest field. func (r *mutationResolver) CreateChannelRequest(ctx context.Context, input graph.CreateChannelRequestInput) (*db.ChannelRequest, error) { if user := middleware.GetUser(ctx, r.UserRepository); user != nil { paymentHashBytes, err := base64.StdEncoding.DecodeString(input.PaymentHash) @@ -175,3 +170,19 @@ func (r *mutationResolver) CreateChannelRequest(ctx context.Context, input graph func (r *Resolver) ChannelRequest() graph.ChannelRequestResolver { return &channelRequestResolver{r} } type channelRequestResolver struct{ *Resolver } + +// !!! WARNING !!! +// The code below was going to be deleted when updating resolvers. It has been copied here so you have +// one last chance to move it out of harms way if you want. There are two reasons this happens: +// - When renaming or deleting a resolver the old code will be put in here. You can safely delete +// it when you're done. +// - You have helper methods in this file. Move them out to keep these resolver files clean. +func (r *channelRequestResolver) FeeBaseMsat(ctx context.Context, obj *db.ChannelRequest) (int, error) { + return int(obj.FeeBaseMsat), nil +} +func (r *channelRequestResolver) FeeProportionalMillionths(ctx context.Context, obj *db.ChannelRequest) (int, error) { + return int(obj.FeeProportionalMillionths), nil +} +func (r *channelRequestResolver) CltvExpiryDelta(ctx context.Context, obj *db.ChannelRequest) (int, error) { + return int(obj.CltvExpiryDelta), nil +} diff --git a/graph/resolver/command.go b/graph/resolver/command.go index 6ef5b5b..ebe5dc7 100644 --- a/graph/resolver/command.go +++ b/graph/resolver/command.go @@ -14,6 +14,7 @@ import ( "github.com/vektah/gqlparser/v2/gqlerror" ) +// StartSession is the resolver for the startSession field. func (r *mutationResolver) StartSession(ctx context.Context, input graph.StartSessionInput) (*graph.StartSession, error) { if userId := middleware.GetUserId(ctx); userId != nil { startSessionRequest := command.NewStartSessionRequest(*userId, input) @@ -31,6 +32,7 @@ func (r *mutationResolver) StartSession(ctx context.Context, input graph.StartSe return nil, gqlerror.Errorf("Not authenticated") } +// StopSession is the resolver for the stopSession field. func (r *mutationResolver) StopSession(ctx context.Context, input graph.StopSessionInput) (*graph.StopSession, error) { if userId := middleware.GetUserId(ctx); userId != nil { stopSessionRequest := command.NewStopSessionRequest(*userId, input) diff --git a/graph/resolver/connector.go b/graph/resolver/connector.go index 72e19b0..68da8bd 100644 --- a/graph/resolver/connector.go +++ b/graph/resolver/connector.go @@ -12,26 +12,32 @@ import ( "github.com/satimoto/go-datastore/pkg/db" ) +// Identifier is the resolver for the identifier field. func (r *connectorResolver) Identifier(ctx context.Context, obj *db.Connector) (*string, error) { return util.NullString(obj.Identifier) } +// Standard is the resolver for the standard field. func (r *connectorResolver) Standard(ctx context.Context, obj *db.Connector) (string, error) { return string(obj.Standard), nil } +// Format is the resolver for the format field. func (r *connectorResolver) Format(ctx context.Context, obj *db.Connector) (string, error) { return string(obj.Format), nil } +// PowerType is the resolver for the powerType field. func (r *connectorResolver) PowerType(ctx context.Context, obj *db.Connector) (string, error) { return string(obj.PowerType), nil } +// TariffID is the resolver for the tariffId field. func (r *connectorResolver) TariffID(ctx context.Context, obj *db.Connector) (*string, error) { return util.NullString(obj.TariffID) } +// Tariff is the resolver for the tariff field. func (r *connectorResolver) Tariff(ctx context.Context, obj *db.Connector) (*db.Tariff, error) { if obj.TariffID.Valid { if tariff, err := r.TariffRepository.GetTariffByUid(ctx, obj.TariffID.String); err == nil { @@ -42,10 +48,12 @@ func (r *connectorResolver) Tariff(ctx context.Context, obj *db.Connector) (*db. return nil, nil } +// TermsAndConditions is the resolver for the termsAndConditions field. func (r *connectorResolver) TermsAndConditions(ctx context.Context, obj *db.Connector) (*string, error) { return util.NullString(obj.TermsAndConditions) } +// LastUpdated is the resolver for the lastUpdated field. func (r *connectorResolver) LastUpdated(ctx context.Context, obj *db.Connector) (string, error) { return obj.LastUpdated.Format(time.RFC3339), nil } diff --git a/graph/resolver/credential.go b/graph/resolver/credential.go index 168a000..322deb9 100644 --- a/graph/resolver/credential.go +++ b/graph/resolver/credential.go @@ -5,16 +5,18 @@ package resolver import ( "context" + "fmt" "log" "github.com/satimoto/go-api/graph" - "github.com/satimoto/go-api/internal/middleware" "github.com/satimoto/go-api/internal/credential" + "github.com/satimoto/go-api/internal/middleware" "github.com/satimoto/go-datastore/pkg/db" "github.com/satimoto/go-datastore/pkg/util" "github.com/vektah/gqlparser/v2/gqlerror" ) +// CreateCredential is the resolver for the createCredential field. func (r *mutationResolver) CreateCredential(ctx context.Context, input graph.CreateCredentialInput) (*db.Credential, error) { if user := middleware.GetUser(ctx, r.UserRepository); user != nil && user.IsAdmin { credentialRequest := credential.NewCreateCredentialRequest(input) @@ -32,6 +34,7 @@ func (r *mutationResolver) CreateCredential(ctx context.Context, input graph.Cre return nil, gqlerror.Errorf("Not authenticated") } +// RegisterCredential is the resolver for the registerCredential field. func (r *mutationResolver) RegisterCredential(ctx context.Context, input graph.RegisterCredentialInput) (*graph.ResultID, error) { if user := middleware.GetUser(ctx, r.UserRepository); user != nil && user.IsAdmin { credentialRequest := credential.NewRegisterCredentialRequest(input) @@ -49,6 +52,25 @@ func (r *mutationResolver) RegisterCredential(ctx context.Context, input graph.R return nil, gqlerror.Errorf("Not authenticated") } +// SyncCredential is the resolver for the syncCredential field. +func (r *mutationResolver) SyncCredential(ctx context.Context, input graph.SyncCredentialInput) (*graph.ResultID, error) { + if user := middleware.GetUser(ctx, r.UserRepository); user != nil && user.IsAdmin { + credentialRequest := credential.NewSyncCredentialRequest(input) + credentialResponse, err := r.OcpiService.SyncCredential(ctx, credentialRequest) + + if err != nil { + util.LogOnError("API028", "Error syncing credential", err) + log.Printf("API028: SyncCredentialRequest=%#v", credentialRequest) + return nil, gqlerror.Errorf("Error syncing credential") + } + + return &graph.ResultID{ID: credentialResponse.Id}, nil + } + + return nil, gqlerror.Errorf("Not authenticated") +} + +// UnregisterCredential is the resolver for the unregisterCredential field. func (r *mutationResolver) UnregisterCredential(ctx context.Context, input graph.UnregisterCredentialInput) (*graph.ResultID, error) { if user := middleware.GetUser(ctx, r.UserRepository); user != nil && user.IsAdmin { credentialRequest := credential.NewUnregisterCredentialRequest(input) diff --git a/graph/resolver/elementrestriction.go b/graph/resolver/elementrestriction.go index e96f8d2..7eb7ba7 100644 --- a/graph/resolver/elementrestriction.go +++ b/graph/resolver/elementrestriction.go @@ -11,46 +11,57 @@ import ( "github.com/satimoto/go-datastore/pkg/util" ) +// StartTime is the resolver for the startTime field. func (r *elementRestrictionResolver) StartTime(ctx context.Context, obj *db.ElementRestriction) (*string, error) { return util.NilString(obj.StartTime), nil } +// EndTime is the resolver for the endTime field. func (r *elementRestrictionResolver) EndTime(ctx context.Context, obj *db.ElementRestriction) (*string, error) { return util.NilString(obj.EndTime), nil } +// StartDate is the resolver for the startDate field. func (r *elementRestrictionResolver) StartDate(ctx context.Context, obj *db.ElementRestriction) (*string, error) { return util.NilString(obj.StartDate), nil } +// EndDate is the resolver for the endDate field. func (r *elementRestrictionResolver) EndDate(ctx context.Context, obj *db.ElementRestriction) (*string, error) { return util.NilString(obj.EndDate), nil } +// MinKwh is the resolver for the minKwh field. func (r *elementRestrictionResolver) MinKwh(ctx context.Context, obj *db.ElementRestriction) (*float64, error) { return util.NilFloat64(obj.MinKwh), nil } +// MaxKwh is the resolver for the maxKwh field. func (r *elementRestrictionResolver) MaxKwh(ctx context.Context, obj *db.ElementRestriction) (*float64, error) { return util.NilFloat64(obj.MaxKwh), nil } +// MinPower is the resolver for the minPower field. func (r *elementRestrictionResolver) MinPower(ctx context.Context, obj *db.ElementRestriction) (*float64, error) { return util.NilFloat64(obj.MinPower), nil } +// MaxPower is the resolver for the maxPower field. func (r *elementRestrictionResolver) MaxPower(ctx context.Context, obj *db.ElementRestriction) (*float64, error) { return util.NilFloat64(obj.MaxPower), nil } +// MinDuration is the resolver for the minDuration field. func (r *elementRestrictionResolver) MinDuration(ctx context.Context, obj *db.ElementRestriction) (*int, error) { return util.NilInt(obj.MinDuration), nil } +// MaxDuration is the resolver for the maxDuration field. func (r *elementRestrictionResolver) MaxDuration(ctx context.Context, obj *db.ElementRestriction) (*int, error) { return util.NilInt(obj.MaxDuration), nil } +// DayOfWeek is the resolver for the dayOfWeek field. func (r *elementRestrictionResolver) DayOfWeek(ctx context.Context, obj *db.ElementRestriction) ([]string, error) { list := []string{} diff --git a/graph/resolver/emailsubscription.go b/graph/resolver/emailsubscription.go index 3cdda14..f879ded 100644 --- a/graph/resolver/emailsubscription.go +++ b/graph/resolver/emailsubscription.go @@ -20,6 +20,7 @@ import ( "github.com/vektah/gqlparser/v2/gqlerror" ) +// CreateEmailSubscription is the resolver for the createEmailSubscription field. func (r *mutationResolver) CreateEmailSubscription(ctx context.Context, input graph.CreateEmailSubscriptionInput) (*db.EmailSubscription, error) { emailSubscription, err := r.EmailSubscriptionRepository.CreateEmailSubscription(ctx, db.CreateEmailSubscriptionParams{ Email: strings.ToLower(input.Email), @@ -58,6 +59,7 @@ func (r *mutationResolver) CreateEmailSubscription(ctx context.Context, input gr return &emailSubscription, nil } +// VerifyEmailSubscription is the resolver for the verifyEmailSubscription field. func (r *mutationResolver) VerifyEmailSubscription(ctx context.Context, input graph.VerifyEmailSubscriptionInput) (*db.EmailSubscription, error) { emailSubscription, err := r.EmailSubscriptionRepository.GetEmailSubscriptionByEmail(ctx, strings.ToLower(input.Email)) diff --git a/graph/resolver/energymix.go b/graph/resolver/energymix.go index 06164d0..bc106c0 100644 --- a/graph/resolver/energymix.go +++ b/graph/resolver/energymix.go @@ -11,18 +11,22 @@ import ( "github.com/satimoto/go-datastore/pkg/db" ) +// EnergySources is the resolver for the energySources field. func (r *energyMixResolver) EnergySources(ctx context.Context, obj *db.EnergyMix) ([]db.EnergySource, error) { return r.EnergyMixRepository.ListEnergySources(ctx, obj.ID) } +// EnvironmentalImpact is the resolver for the environmentalImpact field. func (r *energyMixResolver) EnvironmentalImpact(ctx context.Context, obj *db.EnergyMix) ([]db.EnvironmentalImpact, error) { return r.EnergyMixRepository.ListEnvironmentalImpacts(ctx, obj.ID) } +// SupplierName is the resolver for the supplierName field. func (r *energyMixResolver) SupplierName(ctx context.Context, obj *db.EnergyMix) (*string, error) { return util.NullString(obj.SupplierName) } +// EnergyProductName is the resolver for the energyProductName field. func (r *energyMixResolver) EnergyProductName(ctx context.Context, obj *db.EnergyMix) (*string, error) { return util.NullString(obj.EnergyProductName) } diff --git a/graph/resolver/energysource.go b/graph/resolver/energysource.go index b9268b6..e9a8bf2 100644 --- a/graph/resolver/energysource.go +++ b/graph/resolver/energysource.go @@ -10,6 +10,7 @@ import ( "github.com/satimoto/go-datastore/pkg/db" ) +// Source is the resolver for the source field. func (r *energySourceResolver) Source(ctx context.Context, obj *db.EnergySource) (string, error) { return string(obj.Source), nil } diff --git a/graph/resolver/environmentalimpact.go b/graph/resolver/environmentalimpact.go index 4eb8943..bc6c3b1 100644 --- a/graph/resolver/environmentalimpact.go +++ b/graph/resolver/environmentalimpact.go @@ -10,6 +10,7 @@ import ( "github.com/satimoto/go-datastore/pkg/db" ) +// Source is the resolver for the source field. func (r *environmentalImpactResolver) Source(ctx context.Context, obj *db.EnvironmentalImpact) (string, error) { return string(obj.Source), nil } diff --git a/graph/resolver/evse.go b/graph/resolver/evse.go index 360b369..3b5bf72 100644 --- a/graph/resolver/evse.go +++ b/graph/resolver/evse.go @@ -13,18 +13,22 @@ import ( "github.com/satimoto/go-datastore/pkg/geom" ) +// Identifier is the resolver for the identifier field. func (r *evseResolver) Identifier(ctx context.Context, obj *db.Evse) (*string, error) { return util.NullString(obj.Identifier) } +// Status is the resolver for the status field. func (r *evseResolver) Status(ctx context.Context, obj *db.Evse) (string, error) { return string(obj.Status), nil } +// StatusSchedule is the resolver for the statusSchedule field. func (r *evseResolver) StatusSchedule(ctx context.Context, obj *db.Evse) ([]db.StatusSchedule, error) { return r.EvseRepository.ListStatusSchedules(ctx, obj.ID) } +// Capabilities is the resolver for the capabilities field. func (r *evseResolver) Capabilities(ctx context.Context, obj *db.Evse) ([]graph.TextDescription, error) { list := []graph.TextDescription{} @@ -40,26 +44,32 @@ func (r *evseResolver) Capabilities(ctx context.Context, obj *db.Evse) ([]graph. return list, nil } +// Connectors is the resolver for the connectors field. func (r *evseResolver) Connectors(ctx context.Context, obj *db.Evse) ([]db.Connector, error) { return r.EvseRepository.ListConnectors(ctx, obj.ID) } +// FloorLevel is the resolver for the floorLevel field. func (r *evseResolver) FloorLevel(ctx context.Context, obj *db.Evse) (*string, error) { return util.NullString(obj.FloorLevel) } +// Geom is the resolver for the geom field. func (r *evseResolver) Geom(ctx context.Context, obj *db.Evse) (*geom.Geometry4326, error) { return util.NullGeometry(obj.Geom) } +// PhysicalReference is the resolver for the physicalReference field. func (r *evseResolver) PhysicalReference(ctx context.Context, obj *db.Evse) (*string, error) { return util.NullString(obj.PhysicalReference) } +// Directions is the resolver for the directions field. func (r *evseResolver) Directions(ctx context.Context, obj *db.Evse) ([]db.DisplayText, error) { return r.EvseRepository.ListEvseDirections(ctx, obj.ID) } +// ParkingRestrictions is the resolver for the parkingRestrictions field. func (r *evseResolver) ParkingRestrictions(ctx context.Context, obj *db.Evse) ([]graph.TextDescription, error) { list := []graph.TextDescription{} @@ -73,12 +83,14 @@ func (r *evseResolver) ParkingRestrictions(ctx context.Context, obj *db.Evse) ([ } return list, nil - } + +// Images is the resolver for the images field. func (r *evseResolver) Images(ctx context.Context, obj *db.Evse) ([]db.Image, error) { return r.EvseRepository.ListEvseImages(ctx, obj.ID) } +// LastUpdated is the resolver for the lastUpdated field. func (r *evseResolver) LastUpdated(ctx context.Context, obj *db.Evse) (string, error) { return obj.LastUpdated.Format(time.RFC3339), nil } diff --git a/graph/resolver/exceptionalperiod.go b/graph/resolver/exceptionalperiod.go index 2843e24..8754c8c 100644 --- a/graph/resolver/exceptionalperiod.go +++ b/graph/resolver/exceptionalperiod.go @@ -11,9 +11,12 @@ import ( "github.com/satimoto/go-datastore/pkg/db" ) +// PeriodBegin is the resolver for the periodBegin field. func (r *exceptionalPeriodResolver) PeriodBegin(ctx context.Context, obj *db.ExceptionalPeriod) (string, error) { return obj.PeriodBegin.Format(time.RFC3339), nil } + +// PeriodEnd is the resolver for the periodEnd field. func (r *exceptionalPeriodResolver) PeriodEnd(ctx context.Context, obj *db.ExceptionalPeriod) (string, error) { return obj.PeriodEnd.Format(time.RFC3339), nil } diff --git a/graph/resolver/image.go b/graph/resolver/image.go index be3f096..4918157 100644 --- a/graph/resolver/image.go +++ b/graph/resolver/image.go @@ -13,35 +13,45 @@ import ( "github.com/vektah/gqlparser/v2/gqlerror" ) -func (r *mutationResolver) CreateImage(ctx context.Context, input graph.CreateImageInput) (*db.Image, error) { - params := param.NewCreateImageParams(input) - - i, err := r.ImageRepository.CreateImage(ctx, params) - - if err != nil { - return nil, gqlerror.Errorf("Error creating image") - } - - return &i, nil -} - +// Thumbnail is the resolver for the thumbnail field. func (r *imageResolver) Thumbnail(ctx context.Context, obj *db.Image) (*string, error) { return util.NullString(obj.Thumbnail) } +// Category is the resolver for the category field. func (r *imageResolver) Category(ctx context.Context, obj *db.Image) (string, error) { return string(obj.Category), nil } +// Width is the resolver for the width field. func (r *imageResolver) Width(ctx context.Context, obj *db.Image) (*int, error) { return util.NullInt(obj.Width) } +// Height is the resolver for the height field. func (r *imageResolver) Height(ctx context.Context, obj *db.Image) (*int, error) { return util.NullInt(obj.Width) } -// Logo returns graph.LogoResolver implementation. +// Image returns graph.ImageResolver implementation. func (r *Resolver) Image() graph.ImageResolver { return &imageResolver{r} } type imageResolver struct{ *Resolver } + +// !!! WARNING !!! +// The code below was going to be deleted when updating resolvers. It has been copied here so you have +// one last chance to move it out of harms way if you want. There are two reasons this happens: +// - When renaming or deleting a resolver the old code will be put in here. You can safely delete +// it when you're done. +// - You have helper methods in this file. Move them out to keep these resolver files clean. +func (r *mutationResolver) CreateImage(ctx context.Context, input graph.CreateImageInput) (*db.Image, error) { + params := param.NewCreateImageParams(input) + + i, err := r.ImageRepository.CreateImage(ctx, params) + + if err != nil { + return nil, gqlerror.Errorf("Error creating image") + } + + return &i, nil +} diff --git a/graph/resolver/invoicerequest.go b/graph/resolver/invoicerequest.go index 35318a9..8e8c484 100644 --- a/graph/resolver/invoicerequest.go +++ b/graph/resolver/invoicerequest.go @@ -17,16 +17,46 @@ import ( "github.com/vektah/gqlparser/v2/gqlerror" ) -func (r *queryResolver) ListInvoiceRequests(ctx context.Context) ([]db.InvoiceRequest, error) { - if userId := middleware.GetUserId(ctx); userId != nil { - if invoiceRequests, err := r.InvoiceRequestRepository.ListUnsettledInvoiceRequests(ctx, *userId); err == nil { - return invoiceRequests, nil - } +// Promotion is the resolver for the promotion field. +func (r *invoiceRequestResolver) Promotion(ctx context.Context, obj *db.InvoiceRequest) (*db.Promotion, error) { + if promotion, err := r.PromotionRepository.GetPromotion(ctx, obj.PromotionID); err == nil { + return &promotion, nil } - return nil, gqlerror.Errorf("Not authenticated") + return nil, gqlerror.Errorf("Promotion not found") +} + +// PriceFiat is the resolver for the priceFiat field. +func (r *invoiceRequestResolver) PriceFiat(ctx context.Context, obj *db.InvoiceRequest) (*float64, error) { + return util.NullFloat(obj.PriceFiat) +} + +// PriceMsat is the resolver for the priceMsat field. +func (r *invoiceRequestResolver) PriceMsat(ctx context.Context, obj *db.InvoiceRequest) (*int, error) { + return util.NullInt(obj.PriceMsat) +} + +// CommissionFiat is the resolver for the commissionFiat field. +func (r *invoiceRequestResolver) CommissionFiat(ctx context.Context, obj *db.InvoiceRequest) (*float64, error) { + return util.NullFloat(obj.CommissionFiat) +} + +// CommissionMsat is the resolver for the commissionMsat field. +func (r *invoiceRequestResolver) CommissionMsat(ctx context.Context, obj *db.InvoiceRequest) (*int, error) { + return util.NullInt(obj.CommissionMsat) +} + +// TaxFiat is the resolver for the taxFiat field. +func (r *invoiceRequestResolver) TaxFiat(ctx context.Context, obj *db.InvoiceRequest) (*float64, error) { + return util.NullFloat(obj.TaxFiat) +} + +// TaxMsat is the resolver for the taxMsat field. +func (r *invoiceRequestResolver) TaxMsat(ctx context.Context, obj *db.InvoiceRequest) (*int, error) { + return util.NullInt(obj.TaxMsat) } +// UpdateInvoiceRequest is the resolver for the updateInvoiceRequest field. func (r *mutationResolver) UpdateInvoiceRequest(ctx context.Context, input graph.UpdateInvoiceRequestInput) (*db.InvoiceRequest, error) { if user := middleware.GetUser(ctx, r.UserRepository); user != nil { if !user.NodeID.Valid { @@ -75,39 +105,18 @@ func (r *mutationResolver) UpdateInvoiceRequest(ctx context.Context, input graph return nil, gqlerror.Errorf("Not authenticated") } -func (r *invoiceRequestResolver) CommissionFiat(ctx context.Context, obj *db.InvoiceRequest) (*float64, error) { - return util.NullFloat(obj.CommissionFiat) -} - -func (r *invoiceRequestResolver) CommissionMsat(ctx context.Context, obj *db.InvoiceRequest) (*int, error) { - return util.NullInt(obj.CommissionMsat) -} - -func (r *invoiceRequestResolver) PriceFiat(ctx context.Context, obj *db.InvoiceRequest) (*float64, error) { - return util.NullFloat(obj.PriceFiat) -} - -func (r *invoiceRequestResolver) PriceMsat(ctx context.Context, obj *db.InvoiceRequest) (*int, error) { - return util.NullInt(obj.PriceMsat) -} - -func (r *invoiceRequestResolver) Promotion(ctx context.Context, obj *db.InvoiceRequest) (*db.Promotion, error) { - if promotion, err := r.PromotionRepository.GetPromotion(ctx, obj.PromotionID); err == nil { - return &promotion, nil +// ListInvoiceRequests is the resolver for the listInvoiceRequests field. +func (r *queryResolver) ListInvoiceRequests(ctx context.Context) ([]db.InvoiceRequest, error) { + if userId := middleware.GetUserId(ctx); userId != nil { + if invoiceRequests, err := r.InvoiceRequestRepository.ListUnsettledInvoiceRequests(ctx, *userId); err == nil { + return invoiceRequests, nil + } } - return nil, gqlerror.Errorf("Promotion not found") -} - -func (r *invoiceRequestResolver) TaxFiat(ctx context.Context, obj *db.InvoiceRequest) (*float64, error) { - return util.NullFloat(obj.TaxFiat) -} - -func (r *invoiceRequestResolver) TaxMsat(ctx context.Context, obj *db.InvoiceRequest) (*int, error) { - return util.NullInt(obj.TaxMsat) + return nil, gqlerror.Errorf("Not authenticated") } -// Session returns graph.SessioInvoicenResolver implementation. +// InvoiceRequest returns graph.InvoiceRequestResolver implementation. func (r *Resolver) InvoiceRequest() graph.InvoiceRequestResolver { return &invoiceRequestResolver{r} } type invoiceRequestResolver struct{ *Resolver } diff --git a/graph/resolver/location.go b/graph/resolver/location.go index 2ee9753..5b54407 100644 --- a/graph/resolver/location.go +++ b/graph/resolver/location.go @@ -16,86 +16,17 @@ import ( "github.com/vektah/gqlparser/v2/gqlerror" ) -func (r *queryResolver) GetLocation(ctx context.Context, input graph.GetLocationInput) (*db.Location, error) { - if userId := middleware.GetUserId(ctx); userId != nil { - if input.ID != nil { - if l, err := r.LocationRepository.GetLocation(ctx, *input.ID); err == nil { - return &l, nil - } - } else if input.UID != nil { - if l, err := r.LocationRepository.GetLocationByUid(ctx, *input.UID); err == nil { - return &l, nil - } - } - - return nil, gqlerror.Errorf("Location not found") - } - - return nil, gqlerror.Errorf("Not authenticated") -} - -func (r *queryResolver) ListLocations(ctx context.Context, input graph.ListLocationsInput) ([]graph.ListLocation, error) { - if userId := middleware.GetUserId(ctx); userId != nil { - var list []graph.ListLocation - - params := param.NewListLocationsByGeomParams(input) - - if locations, err := r.LocationRepository.ListLocationsByGeom(ctx, params); err == nil { - for _, l := range locations { - list = append(list, param.NewListLocation(l)) - } - } - - return list, nil - } - - return nil, gqlerror.Errorf("Not authenticated") -} - -func (r *mutationResolver) PublishLocation(ctx context.Context, input graph.PublishLocationInput) (*graph.ResultOk, error) { - if user := middleware.GetUser(ctx, r.UserRepository); user != nil && user.IsAdmin { - if input.ID != nil { - updateLocationPublishParams := db.UpdateLocationPublishParams{ - ID: *input.ID, - Publish: input.Publish, - } - - if err := r.LocationRepository.UpdateLocationPublish(ctx, updateLocationPublishParams); err == nil { - return &graph.ResultOk{Ok: true}, nil - } - } else if input.CredentialID != nil { - updateLocationsPublishByCredentialParams := db.UpdateLocationsPublishByCredentialParams{ - CredentialID: *input.CredentialID, - Publish: input.Publish, - } - - if err := r.LocationRepository.UpdateLocationsPublishByCredential(ctx, updateLocationsPublishByCredentialParams); err == nil { - return &graph.ResultOk{Ok: true}, nil - } - } else if input.PartyID != nil && input.CountryCode != nil { - updateLocationsPublishByPartyAndCountryCodeParams := db.UpdateLocationsPublishByPartyAndCountryCodeParams{ - CountryCode: dbUtil.SqlNullString(input.CountryCode), - PartyID: dbUtil.SqlNullString(input.PartyID), - Publish: input.Publish, - } - - if err := r.LocationRepository.UpdateLocationsPublishByPartyAndCountryCode(ctx, updateLocationsPublishByPartyAndCountryCodeParams); err == nil { - return &graph.ResultOk{Ok: true}, nil - } - } - } - - return nil, gqlerror.Errorf("Not authenticated") -} - +// Type is the resolver for the type field. func (r *locationResolver) Type(ctx context.Context, obj *db.Location) (string, error) { return string(obj.Type), nil } +// Name is the resolver for the name field. func (r *locationResolver) Name(ctx context.Context, obj *db.Location) (*string, error) { return util.NullString(obj.Name) } +// RelatedLocations is the resolver for the relatedLocations field. func (r *locationResolver) RelatedLocations(ctx context.Context, obj *db.Location) ([]graph.AddtionalGeoLocation, error) { list := []graph.AddtionalGeoLocation{} @@ -119,14 +50,17 @@ func (r *locationResolver) RelatedLocations(ctx context.Context, obj *db.Locatio return list, nil } +// Evses is the resolver for the evses field. func (r *locationResolver) Evses(ctx context.Context, obj *db.Location) ([]db.Evse, error) { return r.LocationRepository.ListActiveEvses(ctx, obj.ID) } +// Directions is the resolver for the directions field. func (r *locationResolver) Directions(ctx context.Context, obj *db.Location) ([]db.DisplayText, error) { return r.LocationRepository.ListLocationDirections(ctx, obj.ID) } +// Operator is the resolver for the operator field. func (r *locationResolver) Operator(ctx context.Context, obj *db.Location) (*db.BusinessDetail, error) { if obj.OperatorID.Valid { if businessDetail, err := r.BusinessDetailRepository.GetBusinessDetail(ctx, obj.OperatorID.Int64); err == nil { @@ -137,6 +71,7 @@ func (r *locationResolver) Operator(ctx context.Context, obj *db.Location) (*db. return nil, nil } +// Suboperator is the resolver for the suboperator field. func (r *locationResolver) Suboperator(ctx context.Context, obj *db.Location) (*db.BusinessDetail, error) { if obj.SuboperatorID.Valid { if businessDetail, err := r.BusinessDetailRepository.GetBusinessDetail(ctx, obj.SuboperatorID.Int64); err == nil { @@ -147,6 +82,7 @@ func (r *locationResolver) Suboperator(ctx context.Context, obj *db.Location) (* return nil, nil } +// Owner is the resolver for the owner field. func (r *locationResolver) Owner(ctx context.Context, obj *db.Location) (*db.BusinessDetail, error) { if obj.OwnerID.Valid { if businessDetail, err := r.BusinessDetailRepository.GetBusinessDetail(ctx, obj.OwnerID.Int64); err == nil { @@ -157,6 +93,7 @@ func (r *locationResolver) Owner(ctx context.Context, obj *db.Location) (*db.Bus return nil, nil } +// Facilities is the resolver for the facilities field. func (r *locationResolver) Facilities(ctx context.Context, obj *db.Location) ([]graph.TextDescription, error) { list := []graph.TextDescription{} @@ -172,10 +109,12 @@ func (r *locationResolver) Facilities(ctx context.Context, obj *db.Location) ([] return list, nil } +// TimeZone is the resolver for the timeZone field. func (r *locationResolver) TimeZone(ctx context.Context, obj *db.Location) (*string, error) { return util.NullString(obj.TimeZone) } +// OpeningTime is the resolver for the openingTime field. func (r *locationResolver) OpeningTime(ctx context.Context, obj *db.Location) (*db.OpeningTime, error) { if obj.OpeningTimeID.Valid { if openingTime, err := r.OpeningTimeRepository.GetOpeningTime(ctx, obj.OpeningTimeID.Int64); err == nil { @@ -186,10 +125,12 @@ func (r *locationResolver) OpeningTime(ctx context.Context, obj *db.Location) (* return nil, nil } +// Images is the resolver for the images field. func (r *locationResolver) Images(ctx context.Context, obj *db.Location) ([]db.Image, error) { return r.LocationRepository.ListLocationImages(ctx, obj.ID) } +// EnergyMix is the resolver for the energyMix field. func (r *locationResolver) EnergyMix(ctx context.Context, obj *db.Location) (*db.EnergyMix, error) { if obj.EnergyMixID.Valid { if energyMix, err := r.EnergyMixRepository.GetEnergyMix(ctx, obj.EnergyMixID.Int64); err == nil { @@ -200,10 +141,86 @@ func (r *locationResolver) EnergyMix(ctx context.Context, obj *db.Location) (*db return nil, nil } +// LastUpdated is the resolver for the lastUpdated field. func (r *locationResolver) LastUpdated(ctx context.Context, obj *db.Location) (string, error) { return obj.LastUpdated.Format(time.RFC3339), nil } +// PublishLocation is the resolver for the publishLocation field. +func (r *mutationResolver) PublishLocation(ctx context.Context, input graph.PublishLocationInput) (*graph.ResultOk, error) { + if user := middleware.GetUser(ctx, r.UserRepository); user != nil && user.IsAdmin { + if input.ID != nil { + updateLocationPublishParams := db.UpdateLocationPublishParams{ + ID: *input.ID, + Publish: input.Publish, + } + + if err := r.LocationRepository.UpdateLocationPublish(ctx, updateLocationPublishParams); err == nil { + return &graph.ResultOk{Ok: true}, nil + } + } else if input.CredentialID != nil { + updateLocationsPublishByCredentialParams := db.UpdateLocationsPublishByCredentialParams{ + CredentialID: *input.CredentialID, + Publish: input.Publish, + } + + if err := r.LocationRepository.UpdateLocationsPublishByCredential(ctx, updateLocationsPublishByCredentialParams); err == nil { + return &graph.ResultOk{Ok: true}, nil + } + } else if input.PartyID != nil && input.CountryCode != nil { + updateLocationsPublishByPartyAndCountryCodeParams := db.UpdateLocationsPublishByPartyAndCountryCodeParams{ + CountryCode: dbUtil.SqlNullString(input.CountryCode), + PartyID: dbUtil.SqlNullString(input.PartyID), + Publish: input.Publish, + } + + if err := r.LocationRepository.UpdateLocationsPublishByPartyAndCountryCode(ctx, updateLocationsPublishByPartyAndCountryCodeParams); err == nil { + return &graph.ResultOk{Ok: true}, nil + } + } + } + + return nil, gqlerror.Errorf("Not authenticated") +} + +// GetLocation is the resolver for the getLocation field. +func (r *queryResolver) GetLocation(ctx context.Context, input graph.GetLocationInput) (*db.Location, error) { + if userId := middleware.GetUserId(ctx); userId != nil { + if input.ID != nil { + if l, err := r.LocationRepository.GetLocation(ctx, *input.ID); err == nil { + return &l, nil + } + } else if input.UID != nil { + if l, err := r.LocationRepository.GetLocationByUid(ctx, *input.UID); err == nil { + return &l, nil + } + } + + return nil, gqlerror.Errorf("Location not found") + } + + return nil, gqlerror.Errorf("Not authenticated") +} + +// ListLocations is the resolver for the listLocations field. +func (r *queryResolver) ListLocations(ctx context.Context, input graph.ListLocationsInput) ([]graph.ListLocation, error) { + if userId := middleware.GetUserId(ctx); userId != nil { + var list []graph.ListLocation + + params := param.NewListLocationsByGeomParams(input) + + if locations, err := r.LocationRepository.ListLocationsByGeom(ctx, params); err == nil { + for _, l := range locations { + list = append(list, param.NewListLocation(l)) + } + } + + return list, nil + } + + return nil, gqlerror.Errorf("Not authenticated") +} + // Location returns graph.LocationResolver implementation. func (r *Resolver) Location() graph.LocationResolver { return &locationResolver{r} } diff --git a/graph/resolver/node.go b/graph/resolver/node.go index ddd2fd8..1c2696e 100644 --- a/graph/resolver/node.go +++ b/graph/resolver/node.go @@ -10,6 +10,7 @@ import ( "github.com/satimoto/go-datastore/pkg/db" ) +// Addr is the resolver for the addr field. func (r *nodeResolver) Addr(ctx context.Context, obj *db.Node) (string, error) { return obj.NodeAddr, nil } diff --git a/graph/resolver/openingtime.go b/graph/resolver/openingtime.go index 7a3746d..300f327 100644 --- a/graph/resolver/openingtime.go +++ b/graph/resolver/openingtime.go @@ -10,14 +10,17 @@ import ( "github.com/satimoto/go-datastore/pkg/db" ) +// RegularHours is the resolver for the regularHours field. func (r *openingTimeResolver) RegularHours(ctx context.Context, obj *db.OpeningTime) ([]db.RegularHour, error) { return r.OpeningTimeRepository.ListRegularHours(ctx, obj.ID) } +// ExceptionalOpenings is the resolver for the exceptionalOpenings field. func (r *openingTimeResolver) ExceptionalOpenings(ctx context.Context, obj *db.OpeningTime) ([]db.ExceptionalPeriod, error) { return r.OpeningTimeRepository.ListExceptionalOpeningPeriods(ctx, obj.ID) } +// ExceptionalClosings is the resolver for the exceptionalClosings field. func (r *openingTimeResolver) ExceptionalClosings(ctx context.Context, obj *db.OpeningTime) ([]db.ExceptionalPeriod, error) { return r.OpeningTimeRepository.ListExceptionalClosingPeriods(ctx, obj.ID) } diff --git a/graph/resolver/pricecomponent.go b/graph/resolver/pricecomponent.go index b7b59f6..cb4bfd6 100644 --- a/graph/resolver/pricecomponent.go +++ b/graph/resolver/pricecomponent.go @@ -13,12 +13,12 @@ import ( "github.com/vektah/gqlparser/v2/gqlerror" ) -type OperationalContextVariable map[string]interface{} - +// Type is the resolver for the type field. func (r *priceComponentResolver) Type(ctx context.Context, obj *db.PriceComponent) (string, error) { return string(obj.Type), nil } +// PriceMsat is the resolver for the priceMsat field. func (r *priceComponentResolver) PriceMsat(ctx context.Context, obj *db.PriceComponent) (int, error) { currencyRate, err := r.FerpService.GetRate(obj.Currency) @@ -32,6 +32,7 @@ func (r *priceComponentResolver) PriceMsat(ctx context.Context, obj *db.PriceCom return priceMsat, nil } +// CommissionMsat is the resolver for the commissionMsat field. func (r *priceComponentResolver) CommissionMsat(ctx context.Context, obj *db.PriceComponent) (int, error) { currencyRate, err := r.FerpService.GetRate(obj.Currency) @@ -48,6 +49,7 @@ func (r *priceComponentResolver) CommissionMsat(ctx context.Context, obj *db.Pri return *commissionMsat, nil } +// TaxMsat is the resolver for the taxMsat field. func (r *priceComponentResolver) TaxMsat(ctx context.Context, obj *db.PriceComponent) (*int, error) { taxPercent, err := r.calculateTaxPercent(ctx) @@ -76,12 +78,18 @@ func (r *priceComponentResolver) TaxMsat(ctx context.Context, obj *db.PriceCompo } // PriceComponent returns graph.PriceComponentResolver implementation. -func (r *Resolver) PriceComponent() graph.PriceComponentResolver { - return &priceComponentResolver{r} -} +func (r *Resolver) PriceComponent() graph.PriceComponentResolver { return &priceComponentResolver{r} } type priceComponentResolver struct{ *Resolver } +// !!! WARNING !!! +// The code below was going to be deleted when updating resolvers. It has been copied here so you have +// one last chance to move it out of harms way if you want. There are two reasons this happens: +// - When renaming or deleting a resolver the old code will be put in here. You can safely delete +// it when you're done. +// - You have helper methods in this file. Move them out to keep these resolver files clean. +type OperationalContextVariable map[string]interface{} + func (r *priceComponentResolver) calculateCommissionMsat(ctx context.Context, currencyRate *rate.CurrencyRate, obj *db.PriceComponent) (*int, error) { user := middleware.GetUser(ctx, r.Resolver.UserRepository) diff --git a/graph/resolver/rate.go b/graph/resolver/rate.go index 30340c2..41ab066 100644 --- a/graph/resolver/rate.go +++ b/graph/resolver/rate.go @@ -14,6 +14,7 @@ import ( "github.com/vektah/gqlparser/v2/gqlerror" ) +// GetRate is the resolver for the getRate field. func (r *queryResolver) GetRate(ctx context.Context, currency string) (*graph.Rate, error) { currencyRate, err := r.FerpService.GetRate(currency) @@ -24,8 +25,8 @@ func (r *queryResolver) GetRate(ctx context.Context, currency string) (*graph.Ra } return &graph.Rate{ - Rate: strconv.FormatInt(currencyRate.Rate, 10), - RateMsat: strconv.FormatInt(currencyRate.RateMsat, 10), + Rate: strconv.FormatInt(currencyRate.Rate, 10), + RateMsat: strconv.FormatInt(currencyRate.RateMsat, 10), LastUpdated: currencyRate.LastUpdated.Format(time.RFC3339), }, nil } diff --git a/graph/resolver/referral.go b/graph/resolver/referral.go index 20dd613..e17b573 100644 --- a/graph/resolver/referral.go +++ b/graph/resolver/referral.go @@ -15,7 +15,8 @@ import ( "github.com/vektah/gqlparser/v2/gqlerror" ) -func (r *mutationResolver) CreateReferral(ctx context.Context, input graph.CreateReferralInput) (*graph.ResultID, error) { +// CreateReferral is the resolver for the createReferral field. +func (r *mutationResolver) CreateReferral(ctx context.Context, input graph.CreateReferralInput) (*graph.ResultID, error) { user, err := r.UserRepository.GetUserByReferralCode(ctx, util.SqlNullString(input.Referrer)) if err != nil { @@ -41,9 +42,9 @@ func (r *mutationResolver) CreateReferral(ctx context.Context, input graph.Creat } createReferralParams := db.CreateReferralParams{ - UserID: user.ID, + UserID: user.ID, PromotionID: promotion.ID, - IpAddress: *ipAddress, + IpAddress: *ipAddress, LastUpdated: time.Now(), } diff --git a/graph/resolver/regularhour.go b/graph/resolver/regularhour.go index 4eb1341..3e0f0ca 100644 --- a/graph/resolver/regularhour.go +++ b/graph/resolver/regularhour.go @@ -10,6 +10,7 @@ import ( "github.com/satimoto/go-datastore/pkg/db" ) +// Weekday is the resolver for the weekday field. func (r *regularHourResolver) Weekday(ctx context.Context, obj *db.RegularHour) (int, error) { return int(obj.Weekday), nil } diff --git a/graph/resolver/resolve.go b/graph/resolver/resolver.go similarity index 100% rename from graph/resolver/resolve.go rename to graph/resolver/resolver.go diff --git a/graph/resolver/session.go b/graph/resolver/session.go index 0381dc9..4d6d215 100644 --- a/graph/resolver/session.go +++ b/graph/resolver/session.go @@ -14,6 +14,7 @@ import ( "github.com/vektah/gqlparser/v2/gqlerror" ) +// GetSession is the resolver for the getSession field. func (r *queryResolver) GetSession(ctx context.Context, input graph.GetSessionInput) (*db.Session, error) { if userId := middleware.GetUserId(ctx); userId != nil { if input.ID != nil { @@ -36,22 +37,27 @@ func (r *queryResolver) GetSession(ctx context.Context, input graph.GetSessionIn return nil, gqlerror.Errorf("Not authenticated") } +// AuthorizationID is the resolver for the authorizationId field. func (r *sessionResolver) AuthorizationID(ctx context.Context, obj *db.Session) (*string, error) { return util.NullString(obj.AuthorizationID) } -func (r *sessionResolver) AuthMethod(ctx context.Context, obj *db.Session) (string, error) { - return string(obj.AuthMethod), nil -} - +// StartDatetime is the resolver for the startDatetime field. func (r *sessionResolver) StartDatetime(ctx context.Context, obj *db.Session) (string, error) { return obj.StartDatetime.Format(time.RFC3339), nil } +// EndDatetime is the resolver for the endDatetime field. func (r *sessionResolver) EndDatetime(ctx context.Context, obj *db.Session) (*string, error) { return util.NullTime(obj.EndDatetime, time.RFC3339) } +// AuthMethod is the resolver for the authMethod field. +func (r *sessionResolver) AuthMethod(ctx context.Context, obj *db.Session) (string, error) { + return string(obj.AuthMethod), nil +} + +// Location is the resolver for the location field. func (r *sessionResolver) Location(ctx context.Context, obj *db.Session) (*db.Location, error) { if location, err := r.LocationRepository.GetLocation(ctx, obj.LocationID); err == nil { return &location, nil @@ -60,6 +66,7 @@ func (r *sessionResolver) Location(ctx context.Context, obj *db.Session) (*db.Lo return nil, gqlerror.Errorf("Location not found") } +// Evse is the resolver for the evse field. func (r *sessionResolver) Evse(ctx context.Context, obj *db.Session) (*db.Evse, error) { if evse, err := r.LocationRepository.GetEvse(ctx, obj.EvseID); err == nil { return &evse, nil @@ -68,6 +75,7 @@ func (r *sessionResolver) Evse(ctx context.Context, obj *db.Session) (*db.Evse, return nil, gqlerror.Errorf("Evse not found") } +// Connector is the resolver for the connector field. func (r *sessionResolver) Connector(ctx context.Context, obj *db.Session) (*db.Connector, error) { if connector, err := r.LocationRepository.GetConnector(ctx, obj.ConnectorID); err == nil { return &connector, nil @@ -76,18 +84,22 @@ func (r *sessionResolver) Connector(ctx context.Context, obj *db.Session) (*db.C return nil, gqlerror.Errorf("Connector not found") } +// MeterID is the resolver for the meterId field. func (r *sessionResolver) MeterID(ctx context.Context, obj *db.Session) (*string, error) { return util.NullString(obj.MeterID) } +// SessionInvoices is the resolver for the sessionInvoices field. func (r *sessionResolver) SessionInvoices(ctx context.Context, obj *db.Session) ([]db.SessionInvoice, error) { return r.SessionRepository.ListSessionInvoices(ctx, obj.ID) } +// Status is the resolver for the status field. func (r *sessionResolver) Status(ctx context.Context, obj *db.Session) (string, error) { return string(obj.Status), nil } +// LastUpdated is the resolver for the lastUpdated field. func (r *sessionResolver) LastUpdated(ctx context.Context, obj *db.Session) (string, error) { return obj.LastUpdated.Format(time.RFC3339), nil } diff --git a/graph/resolver/sessioninvoice.go b/graph/resolver/sessioninvoice.go index ed99bf6..38e4fc3 100644 --- a/graph/resolver/sessioninvoice.go +++ b/graph/resolver/sessioninvoice.go @@ -14,6 +14,7 @@ import ( "github.com/vektah/gqlparser/v2/gqlerror" ) +// GetSessionInvoice is the resolver for the getSessionInvoice field. func (r *queryResolver) GetSessionInvoice(ctx context.Context, id int64) (*db.SessionInvoice, error) { if userId := middleware.GetUserId(ctx); userId != nil { if s, err := r.SessionRepository.GetSessionInvoice(ctx, id); err == nil && userId == &s.UserID { @@ -26,15 +27,17 @@ func (r *queryResolver) GetSessionInvoice(ctx context.Context, id int64) (*db.Se return nil, gqlerror.Errorf("Not authenticated") } +// Signature is the resolver for the signature field. func (r *sessionInvoiceResolver) Signature(ctx context.Context, obj *db.SessionInvoice) (string, error) { return hex.EncodeToString(obj.Signature), nil } +// LastUpdated is the resolver for the lastUpdated field. func (r *sessionInvoiceResolver) LastUpdated(ctx context.Context, obj *db.SessionInvoice) (string, error) { return obj.LastUpdated.Format(time.RFC3339), nil } -// Session returns graph.SessioInvoicenResolver implementation. +// SessionInvoice returns graph.SessionInvoiceResolver implementation. func (r *Resolver) SessionInvoice() graph.SessionInvoiceResolver { return &sessionInvoiceResolver{r} } type sessionInvoiceResolver struct{ *Resolver } diff --git a/graph/resolver/statusschedule.go b/graph/resolver/statusschedule.go index f27efac..16a3f04 100644 --- a/graph/resolver/statusschedule.go +++ b/graph/resolver/statusschedule.go @@ -12,13 +12,17 @@ import ( "github.com/satimoto/go-datastore/pkg/db" ) +// PeriodBegin is the resolver for the periodBegin field. func (r *statusScheduleResolver) PeriodBegin(ctx context.Context, obj *db.StatusSchedule) (string, error) { return obj.PeriodBegin.Format(time.RFC3339), nil } +// PeriodEnd is the resolver for the periodEnd field. func (r *statusScheduleResolver) PeriodEnd(ctx context.Context, obj *db.StatusSchedule) (*string, error) { return util.NullTime(obj.PeriodEnd, time.RFC3339) } + +// Status is the resolver for the status field. func (r *statusScheduleResolver) Status(ctx context.Context, obj *db.StatusSchedule) (string, error) { return string(obj.Status), nil } diff --git a/graph/resolver/tariff.go b/graph/resolver/tariff.go index 8c71638..ea8ca39 100644 --- a/graph/resolver/tariff.go +++ b/graph/resolver/tariff.go @@ -12,6 +12,7 @@ import ( "github.com/vektah/gqlparser/v2/gqlerror" ) +// GetTariff is the resolver for the getTariff field. func (r *queryResolver) GetTariff(ctx context.Context, input graph.GetTariffInput) (*db.Tariff, error) { if userId := middleware.GetUserId(ctx); userId != nil { if input.ID != nil { @@ -30,6 +31,7 @@ func (r *queryResolver) GetTariff(ctx context.Context, input graph.GetTariffInpu return nil, gqlerror.Errorf("Not authenticated") } +// CurrencyRate is the resolver for the currencyRate field. func (r *tariffResolver) CurrencyRate(ctx context.Context, obj *db.Tariff) (int, error) { currencyRate, err := r.FerpService.GetRate(obj.Currency) @@ -40,6 +42,7 @@ func (r *tariffResolver) CurrencyRate(ctx context.Context, obj *db.Tariff) (int, return int(currencyRate.Rate), nil } +// CurrencyRateMsat is the resolver for the currencyRateMsat field. func (r *tariffResolver) CurrencyRateMsat(ctx context.Context, obj *db.Tariff) (int, error) { currencyRate, err := r.FerpService.GetRate(obj.Currency) @@ -50,6 +53,7 @@ func (r *tariffResolver) CurrencyRateMsat(ctx context.Context, obj *db.Tariff) ( return int(currencyRate.RateMsat), nil } +// CommissionPercent is the resolver for the commissionPercent field. func (r *tariffResolver) CommissionPercent(ctx context.Context, obj *db.Tariff) (float64, error) { user := middleware.GetUser(ctx, r.UserRepository) @@ -60,6 +64,7 @@ func (r *tariffResolver) CommissionPercent(ctx context.Context, obj *db.Tariff) return user.CommissionPercent, nil } +// TaxPercent is the resolver for the taxPercent field. func (r *tariffResolver) TaxPercent(ctx context.Context, obj *db.Tariff) (*float64, error) { taxPercent, err := r.calculateTaxPercent(ctx) @@ -70,6 +75,7 @@ func (r *tariffResolver) TaxPercent(ctx context.Context, obj *db.Tariff) (*float return taxPercent, nil } +// Elements is the resolver for the elements field. func (r *tariffResolver) Elements(ctx context.Context, obj *db.Tariff) ([]graph.TariffElement, error) { list := []graph.TariffElement{} @@ -94,6 +100,7 @@ func (r *tariffResolver) Elements(ctx context.Context, obj *db.Tariff) ([]graph. return list, nil } +// EnergyMix is the resolver for the energyMix field. func (r *tariffResolver) EnergyMix(ctx context.Context, obj *db.Tariff) (*db.EnergyMix, error) { if obj.EnergyMixID.Valid { if energyMix, err := r.EnergyMixRepository.GetEnergyMix(ctx, obj.EnergyMixID.Int64); err == nil { diff --git a/graph/resolver/user.go b/graph/resolver/user.go index 965f6ca..11e6f90 100644 --- a/graph/resolver/user.go +++ b/graph/resolver/user.go @@ -16,16 +16,7 @@ import ( "github.com/vektah/gqlparser/v2/gqlerror" ) -func (r *queryResolver) GetUser(ctx context.Context) (*db.User, error) { - user := middleware.GetUser(ctx, r.UserRepository) - - if user != nil { - return user, nil - } - - return nil, gqlerror.Errorf("Not authenticated") -} - +// CreateUser is the resolver for the createUser field. func (r *mutationResolver) CreateUser(ctx context.Context, input graph.CreateUserInput) (*db.User, error) { auth, err := r.AuthenticationResolver.Repository.GetAuthenticationByCode(ctx, input.Code) @@ -77,6 +68,7 @@ func (r *mutationResolver) CreateUser(ctx context.Context, input graph.CreateUse return &user, nil } +// UpdateUser is the resolver for the updateUser field. func (r *mutationResolver) UpdateUser(ctx context.Context, input graph.UpdateUserInput) (*db.User, error) { if user := middleware.GetUser(ctx, r.UserRepository); user != nil { updateUserParams := param.NewUpdateUserParams(*user) @@ -92,7 +84,7 @@ func (r *mutationResolver) UpdateUser(ctx context.Context, input graph.UpdateUse updatePendingNotificationByUserParams := db.UpdatePendingNotificationsByUserParams{ DeviceToken: input.DeviceToken, - UserID: user.ID, + UserID: user.ID, } err = r.PendingNotificationRepository.UpdatePendingNotificationsByUser(ctx, updatePendingNotificationByUserParams) @@ -109,10 +101,33 @@ func (r *mutationResolver) UpdateUser(ctx context.Context, input graph.UpdateUse return nil, gqlerror.Errorf("Not authenticated") } +// GetUser is the resolver for the getUser field. +func (r *queryResolver) GetUser(ctx context.Context) (*db.User, error) { + user := middleware.GetUser(ctx, r.UserRepository) + + if user != nil { + return user, nil + } + + return nil, gqlerror.Errorf("Not authenticated") +} + +// ReferralCode is the resolver for the referralCode field. func (r *userResolver) ReferralCode(ctx context.Context, obj *db.User) (*string, error) { return util.NullString(obj.ReferralCode) } +// User returns graph.UserResolver implementation. +func (r *Resolver) User() graph.UserResolver { return &userResolver{r} } + +type userResolver struct{ *Resolver } + +// !!! WARNING !!! +// The code below was going to be deleted when updating resolvers. It has been copied here so you have +// one last chance to move it out of harms way if you want. There are two reasons this happens: +// - When renaming or deleting a resolver the old code will be put in here. You can safely delete +// it when you're done. +// - You have helper methods in this file. Move them out to keep these resolver files clean. func (r *mutationResolver) generateReferralCode(ctx context.Context) string { for { referralCode := util.RandomString(8) @@ -122,9 +137,3 @@ func (r *mutationResolver) generateReferralCode(ctx context.Context) string { } } } - -// User returns graph.UserResolver implementation. -func (r *Resolver) User() graph.UserResolver { return &userResolver{r} } - -type userResolver struct{ *Resolver } - diff --git a/graph/schema/credential.graphqls b/graph/schema/credential.graphqls index 1b1f7a6..bd2749d 100644 --- a/graph/schema/credential.graphqls +++ b/graph/schema/credential.graphqls @@ -20,6 +20,13 @@ input RegisterCredentialInput { clientToken: String } +input SyncCredentialInput { + id: ID! + fromDate: String + countryCode: String + partyId: String +} + input UnregisterCredentialInput { id: ID! } @@ -27,5 +34,6 @@ input UnregisterCredentialInput { extend type Mutation { createCredential(input: CreateCredentialInput!): Credential! registerCredential(input: RegisterCredentialInput!): ResultId! + syncCredential(input: SyncCredentialInput!): ResultId! unregisterCredential(input: UnregisterCredentialInput!): ResultId! } diff --git a/internal/credential/message.go b/internal/credential/message.go index 4a05cdc..be02052 100644 --- a/internal/credential/message.go +++ b/internal/credential/message.go @@ -53,6 +53,15 @@ func NewRegisterCredentialRequest(input graph.RegisterCredentialInput) *ocpirpc. } } +func NewSyncCredentialRequest(input graph.SyncCredentialInput) *ocpirpc.SyncCredentialRequest { + return &ocpirpc.SyncCredentialRequest{ + Id: input.ID, + FromDate: util.DefaultString(input.FromDate, ""), + CountryCode: util.DefaultString(input.CountryCode, ""), + PartyId: util.DefaultString(input.PartyID, ""), + } +} + func NewUnregisterCredentialRequest(input graph.UnregisterCredentialInput) *ocpirpc.UnregisterCredentialRequest { return &ocpirpc.UnregisterCredentialRequest{ Id: input.ID, diff --git a/tools.go b/tools.go new file mode 100644 index 0000000..4f04ccd --- /dev/null +++ b/tools.go @@ -0,0 +1,9 @@ +//go:build tools +// +build tools + +package tools + +import ( + _ "github.com/99designs/gqlgen" + _ "github.com/99designs/gqlgen/graphql/introspection" +)