Corrected function to prevAll()