Conditions | 1 |
Paths | 1 |
Total Lines | 14 |
Code Lines | 9 |
Lines | 0 |
Ratio | 0 % |
Tests | 10 |
CRAP Score | 1 |
Changes | 1 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
7 | 6 | public function getData() |
|
8 | { |
||
9 | 6 | $data = null; |
|
|
|||
10 | 6 | $this->validate('cardReference'); |
|
11 | |||
12 | 6 | $request = new \SimpleXMLElement('<?xml version="1.0" encoding="utf-8"?><request></request>'); |
|
13 | 6 | $request->addChild('store_id', $this->getMerchantId()); |
|
14 | 6 | $request->addChild('api_token', $this->getMerchantKey()); |
|
15 | |||
16 | 6 | $res_delete = $request->addChild('res_delete'); |
|
17 | 6 | $res_delete->addChild('data_key', $this->getCardReference()); |
|
18 | 6 | $data = $request->asXML(); |
|
19 | |||
20 | 6 | return preg_replace('/\n/', '', $data); |
|
21 | } |
||
23 |