variable cleanup

removed unused variables
changed switch statement to now log more verbose as loglevel number increments
captured undefined loglevel to default to most verbose logging