Skip to content

Commit

Permalink
examples: simplify examples/websocket/ping.v (end automatically, when…
Browse files Browse the repository at this point in the history
… the client ends)
  • Loading branch information
spytheman committed Jul 9, 2022
1 parent 7e1c45a commit f56aaa1
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions examples/websocket/ping.v
@@ -1,15 +1,12 @@
module main

import time
import os
import net.websocket

fn main() {
println('press enter to quit...\n')
go start_server()
time.sleep(100 * time.millisecond)
go start_client()
os.get_line()
start_client()?
}

// start_server starts the websocket server, it receives messages
Expand Down

0 comments on commit f56aaa1

Please sign in to comment.