mirror of
https://github.com/yusing/godoxy.git
synced 2026-03-18 15:34:38 +01:00
added golangci-linting, refactor, simplified error msgs and fixed some error handling
This commit is contained in:
@@ -9,7 +9,7 @@ import (
|
||||
"golang.org/x/text/language"
|
||||
)
|
||||
|
||||
// TODO: support other languages
|
||||
// TODO: support other languages.
|
||||
var titleCaser = cases.Title(language.AmericanEnglish)
|
||||
|
||||
func CommaSeperatedList(s string) []string {
|
||||
@@ -31,3 +31,7 @@ func ExtractPort(fullURL string) (int, error) {
|
||||
}
|
||||
return strconv.Atoi(url.Port())
|
||||
}
|
||||
|
||||
func PortString(port uint16) string {
|
||||
return strconv.FormatUint(uint64(port), 10)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user