Handbook
Glossary
next-url ( url -- next-url redirected? )
Vocabulary
long-urls
.
private
Inputs
url
an
object
Outputs
next-url
an
object
redirected?
an
object
Definition
USING:
http
http.client
http.client.private
kernel
long-urls
math
namespaces
;
IN:
long-urls.private
:
next-url
( url -- next-url redirected? )
redirects
inc
redirects
get
max-redirects
get
<=
[
dup
http-head-no-redirects
drop
dup
redirect?
[
nip
"location"
header
t
]
[
drop
f
]
if
]
[
too-many-redirects
]
if
;