             }
             return SiteResponse(status: .NotFound, session: session)
         })
-
-
-        let server = HTTPServer()
-        server.serverAddress = serverConfig.address
-        server.serverPort = serverConfig.port
-        server.addRoutes(routes)
-        server.documentRoot = "./webroot" // Setting the document root will add a default URL route which permits static files to be served from within.
-
-        do {
-            try server.start()
-        } catch {
-            fatalError("\(error)")
-        }
     }
 }
 

            }
            return SiteResponse(status: .NotFound, session: session)
        })

        addRoute(method: .get, uri: "/comic/{cid}/page/{pidx}/edit", handler: { (controller: SiteController, session: SessionInfo, request: HTTPRequest, response: HTTPResponse) in

            if let cid = UInt32(request.urlVariables["cid"] ?? "0"), cid > 0 {
                if let pidx = UInt32(request.urlVariables["pidx"] ?? "0"), pidx > 0 {
                    return controller.editPage(session: session, comicId: cid, pageIndex: pidx)

            }
            return SiteResponse(status: .NotFound, session: session)
        })
        
        addRoute(method: .post, uri: "/comic/{cid}/page/{pidx}/update", handler: { (controller: SiteController, session: SessionInfo, request: HTTPRequest, response: HTTPResponse) in
            
            if let cid = UInt32(request.urlVariables["cid"] ?? "0"), cid > 0 {
                if let pidx = UInt32(request.urlVariables["pidx"] ?? "0"), pidx > 0 {
                    if let content = request.param(name: "content") {
