Clean up toXml

We don't need these hacky things anymore because whoops requires php 5.3 or higher, and this config setting was removed in php 5.3. I assume this code is left over from php 5.2 compatibility.