Remove testing code from consumer
Remove unused code from main