added time check in prefilter