modified cleanDocChannelByTime