Revert "Revert "Cut out code that is not in use""

This reverts commit 7d47746489b0cfb0df3e23d6eb79eadb780b7f2c.