Made listener implement net.Listener

This commit is contained in:
Jacob Stewart
2023-04-20 08:16:16 -04:00
parent 6da336f7c8
commit 3af1a5a631
3 changed files with 3 additions and 4 deletions

View File

@@ -20,13 +20,13 @@ I've tested this on:
# Usage
```
import "github.com/unitoftime/rtcnet"
import "github.com/unitoftime/rtcnet"
```
See [Example](https://github.com/unitoftime/rtcnet/tree/master/example)
# Used By
1. I'm currently using this for an online game I'm building for browser. [You can find it here](www.unit.dev/mmo)
1. I'm currently using this for an online game I'm building for browser. [You can find it here](https://www.unit.dev/mmo)
# License
1. MIT

View File

@@ -55,7 +55,7 @@ func NewListener(address string, config ListenConfig) (*Listener, error) {
return rtcListener, nil
}
func (l *Listener) Accept() (*Conn, error) {
func (l *Listener) Accept() (net.Conn, error) {
select{
case conn := <-l.pendingAccepts:
return conn, nil

View File

@@ -3,7 +3,6 @@
package rtcnet
import (
"time"
"context"
"crypto/tls"