From d09ca461413d804816353a2c78b96998be84a2e4 Mon Sep 17 00:00:00 2001 From: Thomas Breloff Date: Wed, 9 Mar 2016 10:59:33 -0500 Subject: [PATCH] plotlyjs fix --- src/backends/plotlyjs.jl | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/src/backends/plotlyjs.jl b/src/backends/plotlyjs.jl index e1e87119..6349a98a 100644 --- a/src/backends/plotlyjs.jl +++ b/src/backends/plotlyjs.jl @@ -54,12 +54,15 @@ end function _add_annotations{X,Y,V}(plt::Plot{PlotlyJSPackage}, anns::AVec{@compat(Tuple{X,Y,V})}) - # set or add to the annotation_list - if haskey(plt.plotargs, :annotation_list) + # set or add to the annotation_list + @show typeof(anns), typeof(get(plt.plotargs, :annotation_list, nothing)) + if !haskey(plt.plotargs, :annotation_list) + plt.plotargs[:annotation_list] = Any[] + end append!(plt.plotargs[:annotation_list], anns) - else - plt.plotargs[:annotation_list] = anns - end + # else + # plt.plotargs[:annotation_list] = anns + # end end # ----------------------------------------------------------------