Working fine with datetime objects