Skip to content

Commit

Permalink
Revert "windows"
Browse files Browse the repository at this point in the history
This reverts commit 2073f55d1a55306f96d16a269a89df07b018e7a5.
  • Loading branch information
trask committed Nov 29, 2024
1 parent 9526df2 commit 7de0730
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions lychee-lib/src/types/base.rs
Original file line number Diff line number Diff line change
Expand Up @@ -73,12 +73,6 @@ impl TryFrom<&str> for Base {
type Error = ErrorKind;

fn try_from(value: &str) -> Result<Self, Self::Error> {
let path = PathBuf::from(value);
if path.exists() {
// need to check path first since Url::parse accepts windows paths
// e.g. C:\src\lychee and C:/src/lychee are both parsed as URLs
return Ok(Self::Local(PathBuf::from(value)));
}
if let Ok(url) = Url::parse(value) {
if url.cannot_be_a_base() {
return Err(ErrorKind::InvalidBase(
Expand Down

0 comments on commit 7de0730

Please sign in to comment.