From b6f42d806d0e0f5e59c7615cd1558e75c5b314f1 Mon Sep 17 00:00:00 2001 From: Vidhu Kant Sharma Date: Sun, 6 Mar 2022 00:51:36 +0530 Subject: Exported all the errors so programs using this library can customize error messages. --- util/url_generator.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'util/url_generator.go') 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 -- cgit v1.2.3