Flarum\Asset\RevisionCompiler::flush PHP Method

flush() public method

public flush ( )
    public function flush()
    {
        $revision = $this->getRevision();
        $ext = pathinfo($this->filename, PATHINFO_EXTENSION);
        $file = $this->path . '/' . substr_replace($this->filename, '-' . $revision, -strlen($ext) - 1, 0);
        if (file_exists($file)) {
            unlink($file);
        }
    }