on master help sign in
a
commit518db9fb47beaa742c53cdb3396f5edae804f8b1 authorilyakooo0 <ilyakooo0@gmail.com> dateSun 25 Nov 2018, 00:08 (8 years ago) parentf05cfeb
1 file changed+4
Sources/App/routes.swift+4
Sources/App/routes.swift+4
@@ -16,6 +16,10 @@ public func routes(_ router: Router) throws {
1616 return postModel.getPost(for: try req.parameters.next(Int.self), on: req)
1717 }
1818
19+ router.get("openSockets") { (req) in
20+ return OpenSockets.sockets.count
21+ }
22+
1923 // Example of configuring a controller
2024 let todoController = TodoController()
2125 router.get("todos", use: todoController.index)