Skip to content

Commit 34bcd83

Browse files
committed
WIP: update a few settings
1 parent ed6d369 commit 34bcd83

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/Plotly.jl

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ using Reexport
88
export set_credentials_file, RemotePlot, download_plot, savefig_remote, post
99

1010
const _SRC_ATTRS = let
11-
_src_attr_path = joinpath(dirname(PlotlyJS._js_path), "src_attrs.csv")
11+
_src_attr_path = joinpath(PlotlyJS._pkg_root, "deps", "src_attrs.csv")
1212
raw_src_attrs = vec(readdlm(_src_attr_path))
1313
src_attrs = map(x -> x[1:end-3], raw_src_attrs) # remove the `src` suffix
1414
Set(map(Symbol, src_attrs))
@@ -98,8 +98,9 @@ function post(p::Plot; fileopt=get_config().fileopt, filename=nothing, kwargs...
9898
end
9999

100100
function post_v1(p::Plot; kwargs...)
101+
config = get_config()
101102
default_kwargs = Dict{Symbol,Any}(:filename=>"Plot from Julia API",
102-
:world_readable=> true)
103+
:world_readable=> config.world_readable)
103104
default_opts = Dict{Symbol,Any}(:origin => "plot",
104105
:platform => "Julia",
105106
:version => "0.2")
@@ -134,6 +135,7 @@ function post_v1(p::Plot; kwargs...)
134135
end
135136

136137
post(p::PlotlyJS.SyncPlot; kwargs...) = post(p.plot; kwargs...)
138+
post_v1(p::PlotlyJS.SyncPlot; kwargs...) = post_v1(p.plot; kwargs...)
137139

138140
"""
139141
srcify!(p::Plot; fileopt::Symbol=:overwrite, grid_fn=nothing, kwargs...)

0 commit comments

Comments
 (0)