src/Manager.php
public function format($data, $multiple = false)
    {
        if ($multiple === true || $data instanceof Collection) {
            foreach ($data as $key => $value) {
                $data[$key] = $this->runFormatters($value);
            }
        } else {
            $data = $this->runFormatters($data);
        }

        return $data;
    }
public function format($data, $multiple = false)
    {
        if ($multiple === true || $data instanceof Collection) {
            foreach ($data as $key => $value) {
                $data[$key] = $this->runFormatters($value);
            }
        } else {
            $data = $this->runFormatters($data);
        }

        return $data;
    }
public function format ( $ data , $ multiple = false ) { if ( $ multiple === true || $ data instanceof Collection ) { foreach ( $ data as $ key => $ value ) { $ data [ $ key ] = $ this -> runFormatters ( $ value ) ; } } else { $ data = $ this -> runFormatters ( $ data ) ; } return $ data ; }
Format the given data.

@param array|object $data
@param bool         $multiple

@return array|object
Format the given data .