Remove symbols from file name chars because it makes links look like shit
This commit is contained in:
parent
345236b2d9
commit
d84826ae66
2
main.go
2
main.go
@ -97,7 +97,7 @@ func Zeros(path string, size int64) error {
|
|||||||
}
|
}
|
||||||
|
|
||||||
func NameGen(fileNameLength int) string {
|
func NameGen(fileNameLength int) string {
|
||||||
const chars = "abcdefghjkmnpqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ0123456789-_"
|
const chars = "abcdefghjkmnpqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ0123456789"
|
||||||
ll := len(chars)
|
ll := len(chars)
|
||||||
b := make([]byte, fileNameLength)
|
b := make([]byte, fileNameLength)
|
||||||
rand.Read(b) // generates len(b) random bytes
|
rand.Read(b) // generates len(b) random bytes
|
||||||
|
Loading…
Reference in New Issue
Block a user