mirror of
https://github.com/librecaptcha/lc-core.git
synced 2025-03-31 09:13:38 -04:00
add a welcome message to root path
This commit is contained in:
parent
c8db914cfd
commit
f0659da3eb
@ -63,6 +63,19 @@ class Server(address: String, port: Int, captchaManager: CaptchaManager, playgro
|
|||||||
new StringResponse(200, str)
|
new StringResponse(200, str)
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
serverBuilder.GET(
|
||||||
|
"/",
|
||||||
|
(_) => {
|
||||||
|
val str = """
|
||||||
|
<html>
|
||||||
|
<h2>Welcome to LibreCaptcha server</h2>
|
||||||
|
<h3><a href="/demo/index.html">Link to Demo</a></h3>
|
||||||
|
<h3>API is served at <b>/v1/</b></h3>
|
||||||
|
</html>
|
||||||
|
"""
|
||||||
|
new StringResponse(200, str)
|
||||||
|
}
|
||||||
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
val server: picoserve.Server = serverBuilder.build()
|
val server: picoserve.Server = serverBuilder.build()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user