def milliseconds_formatter(time):
    """
    Formats a timedelta object by reurning the total milliseconds with three decimal
    digits, followed by the unit 'ms'.
    """
    if time is None: return None
    return '%0.3f ms' % (1000.0 * time.total_seconds())