modified code to classification type in events