Skip to content

Commit

Permalink
Merge pull request #7 from cloudyr/fix-minor-issues
Browse files Browse the repository at this point in the history
  • Loading branch information
andrewheiss committed May 31, 2016
2 parents 6c4e383 + 95acd17 commit 4e7ed83
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 2 deletions.
1 change: 1 addition & 0 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,4 @@ LazyData: TRUE
URL: https://github.com/cloudyr/limer
BugReports: https://github.com/cloudyr/limer/issues
RoxygenNote: 5.0.1
Suggests: testthat
2 changes: 1 addition & 1 deletion R/call_limer.R
Original file line number Diff line number Diff line change
Expand Up @@ -36,5 +36,5 @@ call_limer <- function(method, params = list(), ...) {
r <- POST(getOption('lime_api'), content_type_json(),
body = jsonlite::toJSON(body.json, auto_unbox = TRUE), ...)

return(jsonlite::fromJSON(content(r, as='text'))$result) # incorporated fix by petrbouchal
return(jsonlite::fromJSON(content(r, as='text', encoding="utf-8"))$result) # incorporated fix by petrbouchal
}
2 changes: 1 addition & 1 deletion R/get_session_key.R
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ get_session_key <- function(username = getOption('lime_username'),
r <- POST(getOption('lime_api'), content_type_json(),
body = jsonlite::toJSON(body.json, auto_unbox = TRUE))

session_key <- as.character(jsonlite::fromJSON(content(r))$result)
session_key <- as.character(jsonlite::fromJSON(content(r, encoding="utf-8"))$result)
session_cache$session_key <- session_key
session_key
}
Expand Down
4 changes: 4 additions & 0 deletions tests/testthat.R
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
library(testthat)
library(limer)

# test_check("limer")

0 comments on commit 4e7ed83

Please sign in to comment.