UNPKG
kubo-rpc-client-esm-cjs
Version:
canary (3.0.1)
latest (3.0.1)
3.0.1
A client library for the Kubo RPC API
github.com/ipfs/js-kubo-rpc-client
ipfs/js-kubo-rpc-client
kubo-rpc-client-esm-cjs
/
dist
/
esm
/
src
/
lib
/
mode-to-string.js
13 lines
•
299 B
JavaScript
View Raw
1
2
3
4
5
6
7
8
9
10
11
12
13
/** *
@param
{
number | string | undefined
}
mode
*/
export
function
modeToString
(
mode
) {
if
(mode ==
null
) {
return
undefined
; }
if
(
typeof
mode ===
'string'
) {
return
mode; }
return
mode.
toString
(
8
).
padStart
(
4
,
'0'
); }
//# sourceMappingURL=mode-to-string.js.map