Go variable scope

I am new in go.
i have go rest api.Started some background events listner when server is started by registering event from main func
I want to stop server from restapi,but i need that registeredevent variable(created when main started) duing rest api call.
how i defined this registeredevent variable so that i can it my controller.

Hello Shweta,

Is there any possibility that you can provide code snippets perhaps so we can help?

1 Like

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.