refactor: extract run function
This commit is contained in:
@@ -11,6 +11,12 @@ import (
|
|||||||
)
|
)
|
||||||
|
|
||||||
func main() {
|
func main() {
|
||||||
|
run()
|
||||||
|
// Keep the Go program running
|
||||||
|
select {}
|
||||||
|
}
|
||||||
|
|
||||||
|
func run() {
|
||||||
debug.Init()
|
debug.Init()
|
||||||
debug.SetDebugLevel(debug.DEBUG_INFO)
|
debug.SetDebugLevel(debug.DEBUG_INFO)
|
||||||
|
|
||||||
@@ -18,8 +24,5 @@ func main() {
|
|||||||
|
|
||||||
// Notify JS that reticulum is ready
|
// Notify JS that reticulum is ready
|
||||||
js.Global().Call("reticulumReady")
|
js.Global().Call("reticulumReady")
|
||||||
|
|
||||||
// Keep the Go program running
|
|
||||||
select {}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user