RequestOptions::allowsRedirects(): bool|null

In this article

Checks whether redirects are allowed.

Return

bool|null True when redirects are allowed (maxRedirects > 0), false when disabled (maxRedirects = 0), null when unspecified (maxRedirects = null).

Source

public function allowsRedirects(): ?bool
{
    if ($this->maxRedirects === null) {
        return null;
    }
    return $this->maxRedirects > 0;
}

Changelog

VersionDescription
0.2.0Introduced.

User Contributed Notes

You must log in before being able to contribute a note or feedback.