Skip to content

Commit

Permalink
rand.Seed was added
Browse files Browse the repository at this point in the history
  • Loading branch information
kochurovro committed Nov 7, 2019
1 parent 7011e89 commit 73d60f5
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions defaults.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,16 @@ package sprig
import (
"bytes"
"encoding/json"
"math/rand"
"reflect"
"strings"
"time"
)

func init() {
rand.Seed(time.Now().UnixNano())
}

// dfault checks whether `given` is set, and returns default if not set.
//
// This returns `d` if `given` appears not to be set, and `given` otherwise.
Expand Down

0 comments on commit 73d60f5

Please sign in to comment.