log.py: enable_pretty_logging() is now idempotent

This pull request makes the enable_pretty_logging() function idempotent.  If called more than once it will no longer result in duplicated log lines (which is a common problem for tornado applications that import things from other tornado applications).