Skip to content

Commit b607904

Browse files
committed
fix(client): raw string is preferred in regexp
1 parent 27c40f7 commit b607904

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

Diff for: client.go

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,19 @@
11
package paperswithcode_go
22

33
import (
4-
"github.com/codingpot/paperswithcode-go/internal/transport"
54
"net/http"
65
"regexp"
76
"strings"
87
"time"
8+
9+
"github.com/codingpot/paperswithcode-go/internal/transport"
910
)
1011

1112
const (
1213
BaseURL = "https://paperswithcode.com/api/v1"
1314
)
1415

15-
var whiteSpaceRegexp = regexp.MustCompile("\\s+")
16+
var whiteSpaceRegexp = regexp.MustCompile(`\s+`)
1617

1718
// ClientOption can be used to swap the default http client or swap the API key
1819
type ClientOption func(*Client)

0 commit comments

Comments
 (0)