Removing unnecessary functions and code.