Added a check to see if the file is empty by checking for the <id></id>
elements. If the id elements can't be found then the file is empty.

Modified error messages to use logger instead of println.