graph-rework-2
noah metz 2023-07-03 19:37:04 -06:00
parent e5c4069cfc
commit dd6b0de414
1 changed files with 2 additions and 5 deletions

@ -700,17 +700,14 @@ func GQLTypeSignalInput() *graphql.InputObject {
func GQLSubscribeSignal(p graphql.ResolveParams) (interface{}, error) {
return GQLSubscribeFn(p, func(signal GraphSignal, p graphql.ResolveParams)(interface{}, error) {
ctx := p.Context.Value("graph_context").(*GraphContext)
ctx.Log.Logf("gql", "SUBSCRIBE_SIGNAL: %+v", p.Source)
return signal, nil
})
}
func GQLSubscribeSelf(p graphql.ResolveParams) (interface{}, error) {
server := p.Context.Value("gql_server").(*GQLThread)
return GQLSubscribeFn(p, func(signal GraphSignal, p graphql.ResolveParams)(interface{}, error) {
ctx := p.Context.Value("graph_context").(*GraphContext)
ctx.Log.Logf("gql", "SUBSCRIBE_SELF: %+v", p.Source)
return p.Source, nil
return server, nil
})
}