Closed mgaynor1 closed 11 months ago
Hi, this is still an issue and we would love to update our package which uses CoordinateCleaner so that we remove our spatial dependency (which is only due to CoordinateCleaner <v3). However, with the updated version, this error => failed tests. Please fix!
HI @mgaynor1, thanks for reporting the issue. It is now fixed on the GitHub version, and will soon be on CRAN.
Thanks so much!
https://github.com/ropensci/CoordinateCleaner/blob/db6ee9b0f961178c25d3973d8d533ab21e8f2363/R/cc_cap.R#L99
This line needs to say
if(is.null(ref) | ncol(ref) = 0)
If the cropped region doesn't contain any capitals, an error will print (see photo). This can be fixed by modifying the if statement in cc_cap. Probably an issue throughout this code, since
is.null(SpatVector)
doesn't tell you if the vector is empty.I