Revert "Extracted input handling"

This reverts commit d8f5a3f0ae3e8e8d173e4280025d1c07285740b3.