Ignore:
Timestamp:
6 Nov 2012, 12:08:03 (12 years ago)
Author:
Henrik Bettermann
Message:

Catch traceback if year < 1900.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.kofa/trunk/src/waeup/kofa/browser/layout.py

    r9221 r9561  
    294294        if isinstance(datetimeobj, datetime):
    295295            tz = getUtility(IKofaUtils).tzinfo
    296             timestamp = to_timezone(
    297                 datetimeobj, tz).strftime("%Y-%m-%d %H:%M:%S")
     296            try:
     297                timestamp = to_timezone(
     298                    datetimeobj, tz).strftime("%Y-%m-%d %H:%M:%S")
     299            except ValueError:
     300                return None
    298301            return timestamp
    299302        else:
Note: See TracChangeset for help on using the changeset viewer.