Skip to content

Commit

Permalink
Replace jsonVal block with nwbib version (#1951)
Browse files Browse the repository at this point in the history
  • Loading branch information
fsteeg committed Sep 11, 2024
1 parent 3e1587d commit fcf01f4
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions web/app/views/tags/result_field.scala.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,10 @@
@import java.util.Optional
@import controllers.resources.Lobid

@jsonVal(p: String) = @{ node match {
case Some(node) => node
case None => if ((doc \\ p).isEmpty) (doc \ p) else (doc \\ p).head
@jsonVal(p: String) = @{
node match {
case Some(node) => (node \ p).asOpt[JsValue].getOrElse(node \ p)
case None => if ((doc \\ p).isEmpty) (doc \ p) else (doc \\ p).head
}
}

Expand Down

0 comments on commit fcf01f4

Please sign in to comment.