Changeset 6580 for main/waeup.sirp/trunk/src/waeup/sirp/utils
- Timestamp:
- 7 Aug 2011, 12:40:01 (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.sirp/trunk/src/waeup/sirp/utils/logger.py
r6578 r6580 165 165 """ 166 166 site = grok.getSite() 167 sitename = '%s' %getattr(site, '__name__', None)167 sitename = getattr(site, '__name__', None) 168 168 loggername = Template(self.logger_name).substitute( 169 dict(sitename= sitename))169 dict(sitename='%s' % sitename)) 170 170 logger = logging.getLogger(loggername) 171 if site is None: 171 if site is None or sitename is None: 172 # Site not added to ZODB yet. Log to commandline 172 173 return logger 173 174 if len(logger.handlers) != 1:
Note: See TracChangeset for help on using the changeset viewer.