TII-143 add some deubuging and fix code format issues

git-svn-id: https://source.sakaiproject.org/contrib/turnitin/branches/TII-142@82795 fdecad78-55fc-0310-b1b2-d7d25cf747c9