Skip to content

Commit 39e8b92

Browse files
committed
fixed long overdue scala style errors
1 parent 9db9077 commit 39e8b92

File tree

7 files changed

+12
-10
lines changed

7 files changed

+12
-10
lines changed

app/actors/ClientSocketActor.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ class ClientSocketActor(out: ActorRef, publisher: ActorRef) extends Actor with E
4747
}
4848
}
4949
)
50-
50+
5151
case SocketMessage(event, payload) =>
5252
Logger.debug("received socket message in client" + SocketMessage)
5353
if (!myEvents.contains(event)) {

app/actors/PublishSocketMessageActor.scala

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ object PublishSocketMessageActor {
2222
}
2323

2424
class PublishSocketMessageActor(irBasePath: String, mat: Materializer, actorSys: ActorSystem) extends Actor with EventJsonSupport {
25-
25+
2626
val eventActorMap: mutable.HashMap[EventType, ListBuffer[ActorRef]] = new mutable.HashMap[EventType, ListBuffer[ActorRef]]()
2727

2828
override def preStart() {
@@ -46,9 +46,9 @@ class PublishSocketMessageActor(irBasePath: String, mat: Materializer, actorSys:
4646
override def postStop() {
4747
Logger.debug("post stop called in publisher" + self)
4848
}
49-
49+
5050
def receive: PartialFunction[Any, Unit] = {
51-
51+
5252
case StopMessage(toStop) =>
5353
Logger.debug("stop received" + toStop)
5454
for ((k, v) <- eventActorMap) v -= toStop

app/controllers/ApiRouter.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,4 +45,4 @@ class ApiRouter @Inject()(irController: InstanceRegistryController, sysControlle
4545
case POST(p"/deleteInstance" ? q"instanceID=$instanceID") => irController.handleRequest(action="/delete", instanceID)
4646

4747
}
48-
}
48+
}

app/controllers/FrontendController.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,4 +39,4 @@ class FrontendController @Inject()(assets: Assets, errorHandler: HttpErrorHandle
3939
def assetOrDefault(resource: String): Action[AnyContent] =
4040
if (resource.contains(".")) assets.at(resource) else index
4141

42-
}
42+
}

app/controllers/InstanceRegistryController.scala

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ class InstanceRegistryController @Inject()(implicit system: ActorSystem, mat: Ma
6262

6363
val instanceRegistryUri = config.get[String]("app.instanceRegistryUri")
6464
val instanceRegistryBasePath = config.get[String]("app.instanceRegistryBasePath")
65-
65+
6666
def instances(componentType: String): Action[AnyContent] = Action.async {
6767

6868
ws.url(instanceRegistryUri + "/instances").addQueryStringParameters("ComponentType" -> componentType).get().map { response =>
@@ -133,9 +133,11 @@ class InstanceRegistryController @Inject()(implicit system: ActorSystem, mat: Ma
133133
.post("")
134134
.map { response =>
135135
response.status match {
136+
// scalastyle:off magic.number
136137
case 202 =>
138+
// scalastyle:on magic.number
137139
Ok(response.body)
138-
case x =>
140+
case x: Any =>
139141
new Status(x)
140142
}
141143
}(myExecutionContext)

app/controllers/SystemInfoController.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,4 +63,4 @@
6363
PlayVersion.current
6464
}
6565

66-
}
66+
}

app/module/Module.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,4 +60,4 @@ class Module extends AbstractModule with ScalaModule {
6060
def configure() {
6161
bind(classOf[MyExecutionContext]).to(classOf[MyExecutionContextImpl])
6262
}
63-
}
63+
}

0 commit comments

Comments
 (0)