fix SoapFault handling to throw proper soap fault to client

This commit is contained in:
Andreas Schamberger 2013-08-19 19:26:11 +02:00
parent 5e6fd5de25
commit 6a5109c526

View File

@ -70,7 +70,12 @@ class SoapServer extends \SoapServer
$soapRequest = SoapRequest::create($request, $this->soapVersion);
// handle actual SOAP request
$soapResponse = $this->handle2($soapRequest);
try {
$soapResponse = $this->handle2($soapRequest);
} catch (\SoapFault $fault) {
// issue an error to the client
$this->fault($fault->faultcode, $fault->faultstring);
}
// send SOAP response to client
$soapResponse->send();