mirror of
https://github.com/denoland/deno.git
synced 2025-03-03 09:31:22 -05:00
style(std/archive): add default value on argument (#8582)
This commit is contained in:
parent
abc883e6a7
commit
6e03917b51
1 changed files with 2 additions and 2 deletions
|
@ -100,8 +100,8 @@ function clean(length: number): Uint8Array {
|
|||
return buffer;
|
||||
}
|
||||
|
||||
function pad(num: number, bytes: number, base?: number): string {
|
||||
const numString = num.toString(base || 8);
|
||||
function pad(num: number, bytes: number, base = 8): string {
|
||||
const numString = num.toString(base);
|
||||
return "000000000000".substr(numString.length + 12 - bytes) + numString;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue