here icon indicating copy to clipboard operation
here copied to clipboard

Empty string breaks paths

Open dsweber2 opened this issue 1 year ago • 0 comments

What happened:

> here::here("a", "", "b")
[1] "~/a//b"

What I expected

> here::here("a", "", "b")
[1] "~/a/b"

This is also a "feature" of file.path. As written above its fairly silly, but if you have a variable that may or may not have a value, having here still work would be useful. In general, here should return something that is guaranteed to be a path (which may or may not exist).

dsweber2 avatar Jul 24 '23 22:07 dsweber2