Removed a pile of unused code