mirror of
https://github.com/NNTmux/newznab-tmux.git
synced 2026-09-02 11:18:56 +00:00
Replace array() with shorthand.
This commit is contained in:
@@ -56,7 +56,7 @@ function create_guids($live, $delete = false)
|
||||
}
|
||||
continue;
|
||||
}
|
||||
$binary_names = array();
|
||||
$binary_names = [];
|
||||
foreach ($nzbfile->file as $file) {
|
||||
$binary_names[] = $file["subject"];
|
||||
}
|
||||
|
||||
@@ -68,7 +68,7 @@ class HashAlgorithms
|
||||
|
||||
$firstArray = $this->_hashesToArray($this->_inputString);
|
||||
|
||||
$secondArray = array();
|
||||
$secondArray = [];
|
||||
foreach ($firstArray as $key => $value) {
|
||||
if (!$this->_writeToFile) {
|
||||
if (in_array($value, $this->_expectedString)) {
|
||||
@@ -89,7 +89,7 @@ class HashAlgorithms
|
||||
$secondArray[$key] = $this->_hashesToArray($value);
|
||||
}
|
||||
|
||||
$thirdArray = array();
|
||||
$thirdArray = [];
|
||||
foreach ($secondArray as $key => $value) {
|
||||
foreach ($value as $key2 => $value2) {
|
||||
if (!$this->_writeToFile) {
|
||||
@@ -171,7 +171,7 @@ class HashAlgorithms
|
||||
);
|
||||
|
||||
$hashTypes = array('md5', 'md4', 'sha1', 'sha256', 'sha512');
|
||||
$tmpArray = array();
|
||||
$tmpArray = [];
|
||||
foreach ($hashTypes as $hash) {
|
||||
foreach ($strings as $key => $value) {
|
||||
$tmpArray[$hash . '_' . $key] = hash($hash, $value, false);
|
||||
|
||||
@@ -44,7 +44,7 @@ if ($groups === false) {
|
||||
echo "No active groups. Fix not needed.\n";
|
||||
} else {
|
||||
|
||||
$queries = array();
|
||||
$queries = [];
|
||||
|
||||
switch ($argv[1]) {
|
||||
case 1:
|
||||
|
||||
@@ -36,7 +36,7 @@ if (!is_writable(NN_RES)) {
|
||||
exit('The (' . NN_RES . ') folder must be writable.' . PHP_EOL);
|
||||
}
|
||||
|
||||
$progress = rw_progress(settings_array());
|
||||
$progress = rw_progress(settings_[]);
|
||||
|
||||
if (!isset($argv[1]) || !is_numeric($argv[1]) && $argv[1] != 'progress' || !isset($argv[2]) ||
|
||||
!in_array($argv[2], ['local', 'remote']) || !isset($argv[3]) ||
|
||||
|
||||
Reference in New Issue
Block a user