mirror of
https://github.com/YGGverse/Yo.git
synced 2026-03-31 17:55:35 +00:00
remove global constant declaration
This commit is contained in:
parent
7cf10079c6
commit
0872e66e15
1 changed files with 2 additions and 7 deletions
|
|
@ -65,12 +65,6 @@ if (false === sem_acquire($semaphore, true))
|
||||||
exit;
|
exit;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Set global options
|
|
||||||
define(
|
|
||||||
'CONFIG_CLI_DOCUMENT_CRAWL_CURL_DOWNLOAD_SIZE_MAX',
|
|
||||||
$config->cli->document->crawl->curl->download->size->max
|
|
||||||
);
|
|
||||||
|
|
||||||
// Init client
|
// Init client
|
||||||
try {
|
try {
|
||||||
|
|
||||||
|
|
@ -203,6 +197,7 @@ foreach($index->search('')
|
||||||
$upload,
|
$upload,
|
||||||
$uploaded
|
$uploaded
|
||||||
) {
|
) {
|
||||||
|
global $config;
|
||||||
global $request;
|
global $request;
|
||||||
|
|
||||||
global $index;
|
global $index;
|
||||||
|
|
@ -223,7 +218,7 @@ foreach($index->search('')
|
||||||
$document->getId()
|
$document->getId()
|
||||||
);
|
);
|
||||||
|
|
||||||
return $downloaded > CONFIG_CLI_DOCUMENT_CRAWL_CURL_DOWNLOAD_SIZE_MAX ? 1 : 0;
|
return $downloaded > $config->cli->document->crawl->curl->download->size->max ? 1 : 0;
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue