Permalink
Browse files

Only catch Exception

  • Loading branch information...
1 parent b2a5635 commit ad42579ef997899ba81c02dc4de35e4ca62ca82d @nafg nafg committed Sep 19, 2012
@@ -237,7 +237,7 @@ object JsonParser {
unquote(buf)
} catch {
case p: ParseException => throw p
- case _ => fail("unexpected string end")
+ case _: Exception => fail("unexpected string end")
}
def parseValue(first: Char) = {
@@ -908,4 +908,4 @@ final case class ToCssBindPromoter(stringSelector: Box[String], css: Box[CssSele
* @return the function that will transform an incoming DOM based on the transform rules
*/
def replaceWith[T](it: => T)(implicit computer: ComputeTransformRules[T]): CssSel = this.#>(it)(computer)
-}
+}
@@ -432,7 +432,7 @@ trait TimeHelpers { self: ControlHelpers =>
case o => toDate(o.toString)
}
} catch {
- case e => logger.debug("Error parsing date "+in, e); Failure("Bad date: "+in, Full(e), Empty)
+ case e: Exception => logger.debug("Error parsing date "+in, e); Failure("Bad date: "+in, Full(e), Empty)
}
}
}
@@ -83,7 +83,7 @@ class FieldFinder[T: ClassManifest](metaMapper: AnyRef, logger: net.liftweb.comm
}
} catch {
- case e =>
+ case e: Exception =>
logger.debug("Not a valid mapped field: %s, got exception: %s".format(meth.getName, e))
false
}

1 comment on commit ad42579

Owner

fmpwizard commented on ad42579 Sep 27, 2012

+1

Please sign in to comment.