HM\BackUpWordPress\File_Backup_Engine::verify_backup PHP Method

verify_backup() public method

This should be called from backup method of any final file backup engine implementations.
public verify_backup ( ) : boolean
return boolean Whether the backup completed successfully.
    public function verify_backup()
    {
        // If there are errors delete the backup file.
        if ($this->get_errors(get_called_class()) && file_exists($this->get_backup_filepath())) {
            unlink($this->get_backup_filepath());
        }
        // If the backup doesn't exist then we must have failed.
        if (!file_exists($this->get_backup_filepath())) {
            return false;
        }
        return true;
    }