Check argument types in random.mix
This commit is contained in:
parent
5c615a14d3
commit
8d77e6597c
|
@ -30,6 +30,7 @@ end
|
||||||
--- Mixes extra entropy into the generator state.
|
--- Mixes extra entropy into the generator state.
|
||||||
--- @param data string The additional entropy to mix.
|
--- @param data string The additional entropy to mix.
|
||||||
local function mix(data)
|
local function mix(data)
|
||||||
|
expect(1, data, "string")
|
||||||
state = blake3.digestKeyed(state, data)
|
state = blake3.digestKeyed(state, data)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue