Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion DESCRIPTION
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Package: plotly
Title: Create Interactive Web Graphics via Plotly's JavaScript Graphing Library
Version: 2.4.2
Version: 2.4.3
Authors@R: c(person("Carson", "Sievert", role = c("aut", "cre"),
email = "cpsievert1@gmail.com"),
person("Chris", "Parmer", role = c("aut", "cph"),
Expand Down
4 changes: 4 additions & 0 deletions NEWS
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
2.4.3 -- 11 Feb 2015

Ensure that we always return HTTPS links. Fixes #455

2.4.2 -- 9 Feb 2015

Fix for on-premise domain configuration.
Expand Down
4 changes: 4 additions & 0 deletions R/process.R
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@ process <- function(resp) {
process.clientresp <- function(resp) {
httr::stop_for_status(resp)
con <- from_JSON(httr::content(resp, as = "text"))
# make sure that we always return a HTTPS link
con$url <- sub("^http[s]?:", "https:", con$url)
if (nchar(con$error) > 0) stop(con$error, call. = FALSE)
if (nchar(con$warning) > 0) warning(con$warning, call. = FALSE)
if (nchar(con$message) > 0) message(con$message, call. = FALSE)
Expand All @@ -27,6 +29,8 @@ process.figure <- function(resp) {
con <- from_JSON(content(resp, as = "text"))
fig <- con$payload$figure
fig$url <- sub("apigetfile/", "~", resp$url)
# make sure that we always return a HTTPS link
con$url <- sub("^http[s]?:", "https:", con$url)
fig <- add_boxed(fig)
fig$data[[1]]$inherit <- FALSE
# any reasonable way to return a data frame?
Expand Down