Skip to content
This repository was archived by the owner on Dec 3, 2024. It is now read-only.

Commit f30413b

Browse files
committed
remove features incompatible with go1.12
1 parent ab80e63 commit f30413b

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

example/main.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ package main
1515

1616
import (
1717
"context"
18-
"errors"
1918
"fmt"
2019
"log"
2120
"math/rand"
@@ -80,7 +79,7 @@ func main() {
8079
Addr: ":" + port,
8180
}
8281
go func() {
83-
if err := srv.ListenAndServe(); err != nil && !errors.Is(err, http.ErrServerClosed) {
82+
if err := srv.ListenAndServe(); err != nil {
8483
log.Printf("server error: %s", err)
8584
}
8685
}()

0 commit comments

Comments
 (0)