Skip to content

Commit

Permalink
Upgrade jsoup
Browse files Browse the repository at this point in the history
  • Loading branch information
farmdawgnation committed Aug 25, 2024
1 parent e40f339 commit b9736cf
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion jsoup/build.sbt
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,4 @@ name := "dispatch-jsoup"
description :=
"Dispatch module providing jsoup html parsing support"

libraryDependencies += "org.jsoup" % "jsoup" % "1.12.1"
libraryDependencies += "org.jsoup" % "jsoup" % "1.18.1"
4 changes: 2 additions & 2 deletions jsoup/src/main/scala/as/soup.scala
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ object Query {
}

object Clean {
import org.jsoup.safety.Whitelist
def apply(wl: Whitelist): Response => String =
import org.jsoup.safety.Safelist
def apply(wl: Safelist): Response => String =
{ r => Jsoup.clean(dispatch.as.String(r), r.getUri().toString, wl) }
}
4 changes: 2 additions & 2 deletions jsoup/src/test/scala/soup.scala
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package dispatch.spec

import org.scalacheck._
import org.jsoup.safety.Whitelist
import org.jsoup.safety.Safelist

object JsoupSpecification
extends Properties("Basic")
Expand Down Expand Up @@ -54,7 +54,7 @@ with DispatchCleanup {
property("handle Cleaning") = forAll(Gen.alphaStr) { (sample: String) =>
val clean = Http.default(
localhost / "unclean" <<? Map("echo" -> sample) > as.jsoup.Clean(
Whitelist.basic)
Safelist.basic)
)
clean() == (SafeFormat format sample)
}
Expand Down

0 comments on commit b9736cf

Please sign in to comment.