0
0
Fork 0
mirror of https://github.com/schollz/croc.git synced 2025-10-11 13:21:00 +02:00

discover faster

This commit is contained in:
Zack Scholl 2018-07-03 06:55:06 -07:00
parent 80c129b411
commit 8373e374cd

View file

@ -137,9 +137,9 @@ func (c *Croc) Receive(codePhrase string) (err error) {
// try to discovery codephrase and server through peer network
discovered, errDiscover := peerdiscovery.Discover(peerdiscovery.Settings{
Limit: 1,
TimeLimit: 1 * time.Second,
TimeLimit: 300 * time.Millisecond,
Delay: 50 * time.Millisecond,
Payload: []byte(codePhrase[:3]),
Payload: []byte("checking"),
})
if errDiscover != nil {
log.Debug(errDiscover)