Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Don't form empty queries; closes #451 #452

Merged
merged 2 commits into from
Jul 24, 2017
Merged

Don't form empty queries; closes #451 #452

merged 2 commits into from
Jul 24, 2017

Conversation

jennybc
Copy link
Member

@jennybc jennybc commented Jun 22, 2017

See #451

Before:

library(httr)
modify_url("http://google.com", query = list(a = NULL))
#> [1] "http://google.com/?="
modify_url("http://google.com", query = list())
#> [1] "http://google.com/?"

After:

devtools::load_all()
#> Loading httr
modify_url("http://google.com", query = list(a = NULL))
#> [1] "http://google.com/"
modify_url("http://google.com", query = list())
#> [1] "http://google.com/"

@jennybc jennybc mentioned this pull request Jun 22, 2017
@hadley hadley merged commit ce50e60 into r-lib:master Jul 24, 2017
@hadley
Copy link
Member

hadley commented Jul 24, 2017

Ooops, I merged slightly too soon. Would you mind doing another PR to add a bullet to news?

@jennybc jennybc deleted the trivial-queries branch July 24, 2017 18:31
jiwalker-usgs pushed a commit to jiwalker-usgs/httr that referenced this pull request Jul 24, 2017
* Make compact() sensitive to length vs. NULL

* Recognize more forms of empty query; closes r-lib#451
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants