Balance::ledger()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 6
Code Lines 3

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 3
dl 0
loc 6
c 1
b 0
f 0
rs 10
cc 1
nc 1
nop 1
1
<?php
2
3
namespace Digikraaft\Paystack;
4
5
class Balance extends ApiResource
6
{
7
    const OBJECT_NAME = 'balance';
8
9
    use ApiOperations\All;
10
11
    /**
12
     * @param array $params
13
     *
14
     * @throws Exceptions\InvalidArgumentException|Exceptions\IsNullException
15
     *
16
     * @return array|object
17
     *
18
     * @link https://developers.paystack.co/reference#fetch-balance-history
19
     *
20
     * @returns array|Object
21
     */
22
    public static function ledger($params = null)
23
    {
24
        self::validateParams($params);
25
        $url = self::buildQueryString('ledger', $params);
26
27
        return static::staticRequest('GET', $url);
28
    }
29
}
30