Removed unused variable currCorefId