Corrects syntax error
Removes unused function