Fix bug
Add debug method to logger
Add logging level and a warning level