mirror of
https://github.com/manualdousuario/marreta.git
synced 2025-09-02 18:51:06 +00:00
se o content retornar com menos de 5kb, ignorar
This commit is contained in:
parent
4baafec194
commit
5983fffb80
1 changed files with 5 additions and 0 deletions
|
@ -521,6 +521,11 @@ class URLAnalyzer
|
||||||
*/
|
*/
|
||||||
private function processContent($content, $host, $url)
|
private function processContent($content, $host, $url)
|
||||||
{
|
{
|
||||||
|
// Check content size / Verifica o tamanho do conteúdo
|
||||||
|
if (strlen($content) < 5120) { // 5KB = 5120 bytes
|
||||||
|
throw new Exception(Language::getMessage('CONTENT_ERROR')['message']);
|
||||||
|
}
|
||||||
|
|
||||||
$dom = new DOMDocument();
|
$dom = new DOMDocument();
|
||||||
$dom->preserveWhiteSpace = true;
|
$dom->preserveWhiteSpace = true;
|
||||||
libxml_use_internal_errors(true);
|
libxml_use_internal_errors(true);
|
||||||
|
|
Loading…
Add table
Reference in a new issue