SoapServer/Client now handle binary files correctly & large tests/fixtures update
Soap Server and Client were breaking binary files during transfer due to invalid Mime Message Parser. Now is it working fine with no errors, but the message parser is about to be rewritten into a better form.
This commit is contained in:
25
src/BeSimple/SoapCommon/Fault/SoapFaultSourceGetter.php
Normal file
25
src/BeSimple/SoapCommon/Fault/SoapFaultSourceGetter.php
Normal file
@ -0,0 +1,25 @@
|
||||
<?php
|
||||
|
||||
namespace BeSimple\SoapCommon\Fault;
|
||||
|
||||
use SoapFault;
|
||||
|
||||
class SoapFaultSourceGetter
|
||||
{
|
||||
public static function isNativeSoapFault(SoapFault $soapFault)
|
||||
{
|
||||
return self::isBeSimpleSoapFault($soapFault) === false;
|
||||
}
|
||||
|
||||
public static function isBeSimpleSoapFault(SoapFault $soapFault)
|
||||
{
|
||||
$defaultPrefix = SoapFaultPrefixEnum::PREFIX_DEFAULT;
|
||||
|
||||
if (strpos($soapFault->getCode(), $defaultPrefix) === 0) {
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user