Commit b76d089f authored by chentao's avatar chentao

Avoid MatchError

parent 2f4cdbce
......@@ -2,7 +2,7 @@ package com.github
import scala.concurrent.ExecutionContext.Implicits.global
import scala.concurrent.Future
import scala.util.{Failure, Try}
import scala.util.{Success, Failure, Try}
/**
* @author Mygod
......@@ -10,6 +10,7 @@ import scala.util.{Failure, Try}
package object shadowsocks {
val handleFailure: PartialFunction[Try[_], Unit] = {
case Success(_) =>
case Failure(e) => e.printStackTrace()
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment