The bug is $event should eval to $false or $null, which it DOES if the warning is disabled (for /say), but if enabled it just halts the script.