node, integtest: Code style

This commit is contained in:
Andras Slemmer
2016-06-27 10:23:48 +01:00
parent ffa9ad1bc9
commit 429d8aab74
6 changed files with 21 additions and 21 deletions

View File

@ -19,7 +19,7 @@ class APIServerImpl(val node: AbstractNode) : APIServer {
override fun serverTime(): LocalDateTime = LocalDateTime.now(node.services.clock)
override fun status(): Response {
return if(node.started) {
return if (node.started) {
Response.ok("started").build()
} else {
Response.status(Response.Status.SERVICE_UNAVAILABLE).entity("not started").build()

View File

@ -71,7 +71,7 @@ class Node(dir: Path, val p2pAddr: HostAndPort, configuration: NodeConfiguration
// when our process shuts down, but we try in stop() anyway just to be nice.
private var nodeFileLock: FileLock? = null
// Todo: Move to node config file
// TODO: Move to node config file
private var webServerPort: Int = p2pAddr.port + 1
override fun makeMessagingService(): MessagingService = ArtemisMessagingService(dir, p2pAddr, serverThread)

View File

@ -36,8 +36,7 @@ class DataUploadServlet : HttpServlet() {
val iterator = upload.getItemIterator(req)
val messages = ArrayList<String>()
if(!iterator.hasNext())
{
if (!iterator.hasNext()) {
resp.sendError(HttpServletResponse.SC_BAD_REQUEST, "Got an upload request with no files")
return
}