updated to handle filtered browsing history