The \if within the \if false branch is not tallied properly? Am I missing something?
Nope, you found a bug. FIxed. Test-case added.
I changed the paragraph to
Lines within false branches are parsed normally, however, any completed queries are not sent to the server, and any completed commands other than conditionals (<command>\if</command>, <command>\elif</command>, <command>\else</command>, <command>\endif</command>) are ignored.
I'm not sure about the ", however, " commas, but I'm sure that I do not know English punctuation rules:-)
Re-worded it again for shorter sentences. Re-mentioned that conditionals are still checked for proper nesting.
* Changed comments to reflect that \if always evalutes <expr> even in a false branch
* Changed \elif to first check if the command is in a proper \if block before evaluating the expression. The invalid boolean message would mask the bigger problem.