Skip to content

Commit

Permalink
Merge branch 'dev'
Browse files Browse the repository at this point in the history
  • Loading branch information
DariusIII committed Aug 16, 2019
2 parents 89b76d1 + d65064f commit e189ca9
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions Blacklight/processing/post/ProcessAdditional.php
Original file line number Diff line number Diff line change
Expand Up @@ -318,9 +318,9 @@ class ProcessAdditional

/**
* Password status of the current release.
* @var string
* @var array
*/
protected $_passwordStatus;
protected $_passwordStatus = [];

/**
* Does the current release have a password?
Expand Down Expand Up @@ -1087,7 +1087,7 @@ protected function _processCompressedData(&$compressedData): bool
$this->_debug('ArchiveInfo: Compressed file has a password.');
}
$this->_releaseHasPassword = true;
$this->_passwordStatus = Releases::PASSWD_RAR;
$this->_passwordStatus = [Releases::PASSWD_RAR];

return false;
}
Expand Down Expand Up @@ -1154,13 +1154,13 @@ protected function _processCompressedFileList(): bool

if (isset($file['pass']) && $file['pass'] === true) {
$this->_releaseHasPassword = true;
$this->_passwordStatus = Releases::PASSWD_RAR;
$this->_passwordStatus = [Releases::PASSWD_RAR];
break;
}

if ($this->_innerFileBlacklist !== false && preg_match($this->_innerFileBlacklist, $file['name'])) {
$this->_releaseHasPassword = true;
$this->_passwordStatus = Releases::PASSWD_POTENTIAL;
$this->_passwordStatus = [Releases::PASSWD_POTENTIAL];
break;
}

Expand Down Expand Up @@ -1216,7 +1216,7 @@ protected function _addFileInfo(&$file): void
if (ReleaseFile::addReleaseFiles($this->_release->id, $file['name'], $file['size'], $file['date'], $file['pass'], '', $file['crc32'] ?? '')) {
$this->_addedFileInfo++;
if ((int) $file['pass'] === 1) {
$this->_passwordStatus = Releases::PASSWD_RAR;
$this->_passwordStatus = [Releases::PASSWD_RAR];
}

if ($this->_echoCLI) {
Expand All @@ -1231,7 +1231,7 @@ protected function _addFileInfo(&$file): void
$this->_debug('Codec spam found, setting release to potentially passworded.');
}
$this->_releaseHasPassword = true;
$this->_passwordStatus = Releases::PASSWD_POTENTIAL;
$this->_passwordStatus = [Releases::PASSWD_POTENTIAL];
} //Run a PreDB filename check on insert to try and match the release
elseif ($file['name'] !== '' && strpos($file['name'], '.') !== 0) {
$this->_release['filename'] = $file['name'];
Expand Down Expand Up @@ -2300,7 +2300,7 @@ protected function _resetReleaseStatus(): void
$this->_foundSample = $this->_processThumbnails ? false : true;
$this->_foundPAR2Info = false;

$this->_passwordStatus = Releases::PASSWD_NONE;
$this->_passwordStatus = [Releases::PASSWD_NONE];
$this->_releaseHasPassword = false;

$this->_releaseGroupName = UsenetGroup::getNameByID($this->_release->groups_id);
Expand Down

0 comments on commit e189ca9

Please sign in to comment.