Page Menu
Home
Musing Studio
Search
Configure Global Search
Log In
Files
F10433488
request.go
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
312 B
Subscribers
None
request.go
View Options
package
impart
import
(
"mime"
"net/http"
)
// ReqJSON returns whether or not the given Request is sending JSON, based on
// the Content-Type header being application/json.
func
ReqJSON
(
r
*
http
.
Request
)
bool
{
ct
,
_
,
_
:=
mime
.
ParseMediaType
(
r
.
Header
.
Get
(
"Content-Type"
))
return
ct
==
"application/json"
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Mon, Jan 20, 3:58 AM (1 d, 20 h)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3137623
Attached To
rI impart
Event Timeline
Log In to Comment