Permalink
Browse files

more cleanup

  • Loading branch information...
1 parent ba3754f commit 670f439c222ecbed41585ba7f3ed6a2c53576d50 @timperrett committed Aug 7, 2011
Showing with 2 additions and 2 deletions.
  1. +2 −2 chapter-4/src/main/scala/example/travel/comet/AuctionServer.scala
@@ -9,8 +9,8 @@ object AuctionServer extends LiftActor {
/**
* Internal state about who's listening for what and what is listening for who!
*/
- private var cometActorAuctions: Map[CometActor,List[Long]] = Map()
- private def auctionCometActors: Map[Long, List[CometActor]] =
+ private var cometActorAuctions = Map.empty[CometActor,List[Long]]
+ private def auctionCometActors =
cometActorAuctions.foldLeft[Map[Long, List[CometActor]]](Map.empty withDefaultValue Nil){
case (prev, (k, vs)) => vs.foldLeft(prev)((prev, v) => prev + (v -> (k::prev(v))))
}

0 comments on commit 670f439

Please sign in to comment.