Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F99783452
toURLEncodedForm.js
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Sun, Jan 26, 14:51
Size
548 B
Mime Type
text/x-java
Expires
Tue, Jan 28, 14:51 (2 d)
Engine
blob
Format
Raw Data
Handle
23790655
Attached To
rOACCT Open Access Compliance Check Tool (OACCT)
toURLEncodedForm.js
View Options
'use strict'
;
import
utils
from
'../utils.js'
;
import
toFormData
from
'./toFormData.js'
;
import
platform
from
'../platform/index.js'
;
export
default
function
toURLEncodedForm
(
data
,
options
)
{
return
toFormData
(
data
,
new
platform
.
classes
.
URLSearchParams
(),
Object
.
assign
({
visitor
:
function
(
value
,
key
,
path
,
helpers
)
{
if
(
platform
.
isNode
&&
utils
.
isBuffer
(
value
))
{
this
.
append
(
key
,
value
.
toString
(
'base64'
));
return
false
;
}
return
helpers
.
defaultVisitor
.
apply
(
this
,
arguments
);
}
},
options
));
}
Event Timeline
Log In to Comment