Skip to content

Commit

Permalink
Fix expression label bug (#5577)
Browse files Browse the repository at this point in the history
  • Loading branch information
teunbrand committed Dec 13, 2023
1 parent a85b06c commit 61142ae
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions R/guide-axis-theta.R
Original file line number Diff line number Diff line change
Expand Up @@ -185,7 +185,7 @@ GuideAxisTheta <- ggproto(
key <- vec_slice(key, !vec_detect_missing(key$.label %||% NA))

# Early exit if drawing no labels
labels <- key$.label
labels <- validate_labels(key$.label)
if (length(labels) < 1) {
return(zeroGrob())
}
Expand Down Expand Up @@ -255,7 +255,7 @@ GuideAxisTheta <- ggproto(

key <- params$key
key <- vec_slice(key, !is.na(key$.label) & nzchar(key$.label))
labels <- key$.label
labels <- validate_labels(key$.label)
if (length(labels) == 0 || inherits(elements$text, "element_blank")) {
return(list(offset = offset))
}
Expand Down

0 comments on commit 61142ae

Please sign in to comment.