Skip to content

Commit

Permalink
fix(checkurls): Trim renaming suffix in url (ScoopInstaller#3677)
Browse files Browse the repository at this point in the history
  • Loading branch information
Chawye Hsu authored and r15ch13 committed Oct 6, 2019
1 parent 9c04608 commit 15e11e6
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions bin/checkurls.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,9 @@ Write-Host ']ailed'
Write-Host ' | | |'

function test_dl([String] $url, $cookies) {
# Trim renaming suffix, prevent getting 40x response
$url = ($url -split '#/')[0]

$wreq = [Net.WebRequest]::Create($url)
$wreq.Timeout = $Timeout * 1000
if ($wreq -is [Net.HttpWebRequest]) {
Expand Down

0 comments on commit 15e11e6

Please sign in to comment.