src/Models/ApiObject.php
public function refresh()
    {
        if ($this->ID && $this->HailID) {
            try {
                $api_client = new Client();
                $data = $api_client->getOne($this);
            } catch (\Exception $ex) {
                return $this;
            }
            if (count($data) > 0) {
                $this->importHailData($data);
            }
        }

        return $this;
    }
public function refresh()
    {
        if ($this->ID && $this->HailID) {
            try {
                $api_client = new Client();
                $data = $api_client->getOne($this);
            } catch (\Exception $ex) {
                return $this;
            }
            if (count($data) > 0) {
                $this->importHailData($data);
            }
        }

        return $this;
    }
public function refresh ( ) { if ( $ this -> ID && $ this -> HailID ) { try { $ api_client = new Client ( ) ; $ data = $ api_client -> getOne ( $ this ) ; } catch ( \ Exception $ ex ) { return $ this ; } if ( count ( $ data ) > 0 ) { $ this -> importHailData ( $ data ) ; } } return $ this ; }
Retrieves the latest version of this object from the Hail API

@return ApiObject
Retrieves the latest version of this object from the Hail API