public function getParsedBodyParam($key, $default = null)
    {
        $postParams = $this->getParsedBody();
        $result = $default;
        if (is_array($postParams) && isset($postParams[$key])) {
            $result = $postParams[$key];
        } elseif (is_object($postParams) && property_exists($postParams, $key)) {
            $result = $postParams->$key;
        }

        return $result;
    }
public function getParsedBodyParam($key, $default = null)
    {
        $postParams = $this->getParsedBody();
        $result = $default;
        if (is_array($postParams) && isset($postParams[$key])) {
            $result = $postParams[$key];
        } elseif (is_object($postParams) && property_exists($postParams, $key)) {
            $result = $postParams->$key;
        }

        return $result;
    }
public function getParsedBodyParam ( $ key , $ default = null ) { $ postParams = $ this -> getParsedBody ( ) ; $ result = $ default ; if ( is_array ( $ postParams ) && isset ( $ postParams [ $ key ] ) ) { $ result = $ postParams [ $ key ] ; } elseif ( is_object ( $ postParams ) && property_exists ( $ postParams , $ key ) ) { $ result = $ postParams -> $ key ; } return $ result ; }
Fetch parameter value from request body.

Note: This method is not part of the PSR-7 standard.

@param string $key
@param mixed  $default

@return mixed
Fetch parameter value from request body .