request.end()
Previously this would result in an exception. Thanks @magnuslundstedt for finding the bug!