Function requestHasBody [src]

Returns true if a request of this method is allowed to have a body Actual behavior from servers may vary and should still be checked

Prototype

pub fn requestHasBody(self: Method) bool

Parameters

self: Method

Source

pub fn requestHasBody(self: Method) bool { return switch (self) { .POST, .PUT, .PATCH => true, .GET, .HEAD, .DELETE, .CONNECT, .OPTIONS, .TRACE => false, else => true, }; }