diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/uuid.go | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/src/uuid.go b/src/uuid.go index fa1e958..c99f20b 100644 --- a/src/uuid.go +++ b/src/uuid.go @@ -4,13 +4,14 @@ import ( "crypto/rand" "encoding/binary" "encoding/hex" - "errors" "flag" "fmt" "io" "os" "strings" "time" + + gt "gotext" ) @@ -39,11 +40,15 @@ var ( dashIndexes = []int{ 8, 13, 18, 23 } randomReader = rand.Reader - ErrBadLength = errors.New( + ErrBadLength = gt.Error(gt.Gettext( "uuid: str isn't of the correct length", - ) - ErrBadDashCount = errors.New("uuid: Bad count of dashes in string") - ErrBadDashPosition = errors.New("uuid: Bad char in string") + )) + ErrBadDashCount = gt.Error(gt.Gettext( + "uuid: Bad count of dashes in string", + )) + ErrBadDashPosition = gt.Error(gt.Gettext( + "uuid: Bad char in string", + )) DefaultVersion = 4 |