public function sendBadRequest($pCode, $pMessage)
    {
        if (is_object($pMessage) && $pMessage->xdebug_message) $pMessage = $pMessage->xdebug_message;
        $msg = array('error' => $pCode, 'message' => $pMessage);
        if (!$this->getClient()) throw new \Exception('client_not_found_in_ServerController');
        return $this->getClient()->sendResponse('400', $msg);
    }
public function sendBadRequest($pCode, $pMessage)
    {
        if (is_object($pMessage) && $pMessage->xdebug_message) $pMessage = $pMessage->xdebug_message;
        $msg = array('error' => $pCode, 'message' => $pMessage);
        if (!$this->getClient()) throw new \Exception('client_not_found_in_ServerController');
        return $this->getClient()->sendResponse('400', $msg);
    }
public function sendBadRequest ( $ pCode , $ pMessage ) { if ( is_object ( $ pMessage ) && $ pMessage -> xdebug_message ) $ pMessage = $ pMessage -> xdebug_message ; $ msg = array ( 'error' => $ pCode , 'message' => $ pMessage ) ; if ( ! $ this -> getClient ( ) ) throw new \ Exception ( 'client_not_found_in_ServerController' ) ; return $ this -> getClient ( ) -> sendResponse ( '400' , $ msg ) ; }
Sends a 'Bad Request' response to the client.

@param $pCode
@param $pMessage
@throws \Exception
@return string
Sends a Bad Request response to the client .