aboutsummaryrefslogtreecommitdiff
path: root/util
diff options
context:
space:
mode:
authorVidhu Kant Sharma <vidhukant@protonmail.ch>2022-03-06 00:51:36 +0530
committerVidhu Kant Sharma <vidhukant@protonmail.ch>2022-03-06 00:51:36 +0530
commitb6f42d806d0e0f5e59c7615cd1558e75c5b314f1 (patch)
treec9c014759f62c44520be305a60546d08140876f4 /util
parent95b8ab702708538ccaf26efd141b448148ac6d6d (diff)
Exported all the errors so programs using this library can customize error messages.
Diffstat (limited to 'util')
-rw-r--r--util/url_generator.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/util/url_generator.go b/util/url_generator.go
index e6799b5..d0f5eea 100644
--- a/util/url_generator.go
+++ b/util/url_generator.go
@@ -17,13 +17,13 @@
package util
import (
- "errors"
+ e "github.com/MikunoNaka/MAL2Go/errhandlers"
)
func UrlGenerator(baseUrl string, names []string, values [][]string, isPrimary bool) (string, error) {
// length of names and values should be same
if cap(names) != cap(values) {
- return "", errors.New("util.UrlGenerator: Error: Length of names and values don't match.")
+ return "", e.URLNameValueError
}
var fields string