Various updates, removals of useless code, and simplifications