Conditions | 1 |
Paths | 1 |
Total Lines | 9 |
Code Lines | 6 |
Lines | 0 |
Ratio | 0 % |
Tests | 0 |
CRAP Score | 2 |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
45 | protected function loadPricing(SimpleXMLElement $node) |
||
46 | { |
||
47 | $this->units = (string) $node->UNITS; |
||
|
|||
48 | $this->unitPrice = (string) $node->UNITPRICE; |
||
49 | $this->total = (string) $node->TOTAL; |
||
50 | $this->subAccountFund = (string) $node->SUBACCTFUND; |
||
51 | $this->subAccountSec = (string) $node->SUBACCTSEC; |
||
52 | |||
53 | return $this; |
||
54 | } |
||
56 |
This check looks for assignments to scalar types that may be of the wrong type.
To ensure the code behaves as expected, it may be a good idea to add an explicit type cast.