Remove TestController
This commit is contained in:
parent
d9346a29f7
commit
09643eca0c
@ -12,6 +12,5 @@ import org.kodein.di.generic.singleton
|
||||
val controllerModule = Kodein.Module(name = "Controller") {
|
||||
bind() from setBinding<KodeinController>()
|
||||
|
||||
bind<KodeinController>().inSet() with singleton { TestController(this.kodein) }
|
||||
bind<KodeinController>().inSet() with singleton { UserController(this.kodein) }
|
||||
}
|
||||
@ -1,22 +0,0 @@
|
||||
package be.vandewalleh.controllers
|
||||
|
||||
import io.ktor.application.call
|
||||
import io.ktor.locations.Location
|
||||
import io.ktor.locations.get
|
||||
import io.ktor.response.respond
|
||||
import io.ktor.routing.Routing
|
||||
import org.kodein.di.Kodein
|
||||
|
||||
class TestController(kodein: Kodein) : KodeinController(kodein) {
|
||||
override fun Routing.registerRoutes() {
|
||||
get<Routes.Hello>{
|
||||
data class Response(val msg: String)
|
||||
call.respond(Response("Hello"))
|
||||
}
|
||||
}
|
||||
|
||||
object Routes {
|
||||
@Location("/hello")
|
||||
class Hello
|
||||
}
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user