fix init indentation
move trailing slash and custom method logic into the http server