Refactored and renamed stuff.