Corrected before filter logic