Cleanup code complexity