Cleanup

* Fixed type
* Removed unused variable
* Fixed xml param reference.