Removed function versioning, updated sort function, and lots of other random cleanup.