Minor bugfixes of SoapFault handling
SoapFault is now properly prefixed so that SoapFaultSourceGetter identifies them correctly, missing exceptions option is now processed in SoapServer
This commit is contained in:
@ -4,7 +4,7 @@ namespace BeSimple\SoapCommon\Fault;
|
||||
|
||||
class SoapFaultEnum
|
||||
{
|
||||
const SOAP_FAULT_WSDL = 'wsdl';
|
||||
const SOAP_FAULT_HTTP = 'http';
|
||||
const SOAP_FAULT_SOAP_CLIENT_ERROR = 'soap-client-error';
|
||||
const SOAP_FAULT_WSDL = SoapFaultPrefixEnum::PREFIX_DEFAULT.'-'.'wsdl';
|
||||
const SOAP_FAULT_HTTP = SoapFaultPrefixEnum::PREFIX_DEFAULT.'-'.'http';
|
||||
const SOAP_FAULT_SOAP_CLIENT_ERROR = SoapFaultPrefixEnum::PREFIX_DEFAULT.'-'.'soap-client-error';
|
||||
}
|
||||
|
@ -13,13 +13,13 @@ class SoapFaultSourceGetter
|
||||
|
||||
public static function isBeSimpleSoapFault(SoapFault $soapFault)
|
||||
{
|
||||
$defaultPrefix = SoapFaultPrefixEnum::PREFIX_DEFAULT;
|
||||
$nativeSoapFaultPrefix = SoapFaultPrefixEnum::PREFIX_DEFAULT.'-';
|
||||
|
||||
if (strpos($soapFault->getCode(), $defaultPrefix) === 0) {
|
||||
if (strpos($soapFault->faultcode, $nativeSoapFaultPrefix) === 0) {
|
||||
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
return true;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user