Browse code

forgot to test axis is null

jokergoo authored on 14/11/2018 12:02:20
Showing1 changed files

... ...
@@ -782,6 +782,10 @@ anno_points = function(x, which = c("column", "row"), border = TRUE, gp = gpar()
782 782
 
783 783
 update_anno_extend = function(anno, axis_grob, axis_param) {
784 784
 	extended = anno@extended
785
+	if(is.null(axis_grob)) {
786
+		return(extended)
787
+	}
788
+
785 789
 	if(axis_param$facing == "outside") {
786 790
 		if(axis_param$side == "left") {
787 791
 			extended[[2]] = convertWidth(grobWidth(axis_grob), "mm", valueOnly = TRUE)