src/Message/Response.php
public function getTransactionReference()
    {
        if (isset($this->data['object']) && 'charge' === $this->data['object']) {
            return $this->data['id'];
        }
        if (isset($this->data['error']) && isset($this->data['error']['charge'])) {
            return $this->data['error']['charge'];
        }

        return null;
    }
public function getTransactionReference()
    {
        if (isset($this->data['object']) && 'charge' === $this->data['object']) {
            return $this->data['id'];
        }
        if (isset($this->data['error']) && isset($this->data['error']['charge'])) {
            return $this->data['error']['charge'];
        }

        return null;
    }
public function getTransactionReference ( ) { if ( isset ( $ this -> data [ 'object' ] ) && 'charge' === $ this -> data [ 'object' ] ) { return $ this -> data [ 'id' ] ; } if ( isset ( $ this -> data [ 'error' ] ) && isset ( $ this -> data [ 'error' ] [ 'charge' ] ) ) { return $ this -> data [ 'error' ] [ 'charge' ] ; } return null ; }
Get the transaction reference.

@return string|null
Get the transaction reference .