1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 13:38:11 +00:00

LibWeb: Remove nonsensical assignment in script-became-ready callback

We don't need to set m_script_ready in the callback that gets invoked
precisely because m_script_ready has been set. :^)
This commit is contained in:
Andreas Kling 2021-09-26 02:05:54 +02:00
parent 65e0f8184d
commit bfec16ce46

View file

@ -380,10 +380,8 @@ void HTMLScriptElement::prepare_script()
// 1. If the element is not now the first element in the list of scripts // 1. If the element is not now the first element in the list of scripts
// that will execute in order as soon as possible to which it was added above, // that will execute in order as soon as possible to which it was added above,
// then mark the element as ready but return without executing the script yet. // then mark the element as ready but return without executing the script yet.
if (this != &m_preparation_time_document->scripts_to_execute_as_soon_as_possible().first()) { if (this != &m_preparation_time_document->scripts_to_execute_as_soon_as_possible().first())
m_script_ready = true;
return; return;
}
for (;;) { for (;;) {
// 2. Execution: Execute the script block corresponding to the first script element // 2. Execution: Execute the script block corresponding to the first script element