XWIKI-9779: XWiki.Registration executes $doAfterRegistration twice
* Fixed remaining #end

Caleb still needs to update the comment. I didn't do it since I don't fully understand the code logic.