Pantheon\Terminus\Models\SavedToken::saveToDir PHP Method

saveToDir() public method

Saves this token to a file in the tokens cache dir
public saveToDir ( )
    public function saveToDir()
    {
        if (!$this->id) {
            throw new TerminusException('Could not save the machine token because it is missing an ID');
        }
        $this->set('date', time());
        $this->getDataStore()->set($this->id, $this->attributes);
    }