Skip to content

Commit b979f5f

Browse files
committed
Further improved code quality
1 parent 654e612 commit b979f5f

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

src/main/scala/de/upb/cs/swt/delphi/crawler/processing/ElasticEdgeSearchActor.scala

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ class ElasticEdgeSearchActor(client: ElasticClient) extends Actor with ActorLogg
3636

3737
//Splits the set of methods in "batch" sized chucks before passing them to the search function, to prevent
3838
// the construction of a search too large to be run
39-
private def segmentFun(fx: ((Set[UnresolvedMethodCall], List[MavenIdentifier]) => (Set[UnresolvedMethodCall], Set[MappedEdge])), batch: Int)
39+
private def segmentFun(fx: (Set[UnresolvedMethodCall], List[MavenIdentifier]) => (Set[UnresolvedMethodCall], Set[MappedEdge]), batch: Int)
4040
(mx: Set[UnresolvedMethodCall], ix: List[MavenIdentifier]): (Set[UnresolvedMethodCall], Set[MappedEdge]) = {
4141
if (mx.size > batch) {
4242
mx.splitAt(batch) match { case (currSeg, restSeg) =>
@@ -62,7 +62,7 @@ class ElasticEdgeSearchActor(client: ElasticClient) extends Actor with ActorLogg
6262
}
6363
}
6464

65-
def searchEsDb(calls: List[UnresolvedMethodCall], id: MavenIdentifier): (UnresolvedMethodCall) => Boolean = {
65+
def searchEsDb(calls: List[UnresolvedMethodCall], id: MavenIdentifier): UnresolvedMethodCall => Boolean = {
6666
val resp: Response[MultiSearchResponse] = client.execute{
6767
multi(
6868
for(call <- calls) yield genSearchDef(call, id)
@@ -82,7 +82,6 @@ class ElasticEdgeSearchActor(client: ElasticClient) extends Actor with ActorLogg
8282
ids.headOption match {
8383
case None => (calls, Set[MappedEdge]())
8484
case Some(id) => {
85-
val id = ids.head
8685
def exists = searchEsDb(calls.toList, id)
8786
calls.partition(exists) match {
8887
case (hits, misses) => {

0 commit comments

Comments
 (0)