fixed a timespan bug