Do not throw exception if we don't have daily free
All checks were successful
Push image to registry / build-image (push) Successful in 4m42s

This commit is contained in:
2025-06-05 16:35:05 +02:00
parent d498203147
commit 70cd2a41b1

View File

@ -226,7 +226,11 @@ class HellcaseJob extends BrowserJob implements ShouldBeUniqueUntilProcessing
private function getDailyFree(Browser $browser)
{
$browser->visit('https://hellcase.com/dailyfree');
$browser->waitForText("Get Daily free loot", 30, true);
try {
$browser->waitForText("Get Daily free loot", 30, true);
} catch (\Exception $e) {
return; // Pobably means we do not have access to a daily free loot
}
// Do we fill the conditions ?
if (sizeof(value: $browser->driver->findElements(WebDriverBy::xpath('//p[contains(text(), "Fulfill the conditions below")]'))) > 0) {