Logging only if debug
Fix naming conventions