Hypernode\Magento\Command\Hypernode\Patches\ListCommand::_loadPatchFile PHP Method

_loadPatchFile() protected method

Use to load the patches array with applied patches.
protected _loadPatchFile ( ) : void
return void Thanks @philwinkle - https://github.com/philwinkle/Philwinkle_AppliedPatches/
    protected function _loadPatchFile()
    {
        $ioAdapter = new \Varien_Io_File();
        if (!$ioAdapter->fileExists($this->patchFile)) {
            return;
        }
        $ioAdapter->open(array('path' => $ioAdapter->dirname($this->patchFile)));
        $ioAdapter->streamOpen($this->patchFile, 'r');
        while ($buffer = $ioAdapter->streamRead()) {
            if (stristr($buffer, '|')) {
                list($date, $patch) = array_map('trim', explode('|', $buffer));
                $this->appliedPatches[$patch] = true;
            }
        }
        $ioAdapter->streamClose();
    }