fix default value in JS when date_range is None