Remove unused code
Revert changes that were applied accidentally with a previous commit

This partially reverts commit 060cad79f40b873833dcdc80faa7a2f3142d8d0e.