Deleting some unused functions.
Refactoring.