If you format your code in a decent manner, the error becomes obvious:
// a while loop
while (condition = true)
{
if (this_condition = true)
debugLog("Condition is true.");
}
else
{
debugLog("Condition is false.")
}
}
And it becomes obvious BECAUSE of the "evil" braces.