aboutsummaryrefslogtreecommitdiff
path: root/util
diff options
context:
space:
mode:
Diffstat (limited to 'util')
-rw-r--r--util/rand.go8
1 files changed, 4 insertions, 4 deletions
diff --git a/util/rand.go b/util/rand.go
index ffe97a0..1e4ec95 100644
--- a/util/rand.go
+++ b/util/rand.go
@@ -10,7 +10,7 @@ var (
runes_length = len(runes)
)
-func NewRandId(n int) (string, error) {
+func NewRandID(n int) (string, error) {
data := make([]rune, n)
for i := range data {
num, err := rand.Int(rand.Reader, big.NewInt(int64(runes_length)))
@@ -22,10 +22,10 @@ func NewRandId(n int) (string, error) {
return string(data), nil
}
-func NewSessionId() (string, error) {
- return NewRandId(24)
+func NewSessionID() (string, error) {
+ return NewRandID(24)
}
func NewCSRFToken() (string, error) {
- return NewRandId(24)
+ return NewRandID(24)
}