Skip to content
Myr

Complete unnesting of if statements in cookie loop

Before adoption: this commit came in with the history the project adopted, so no landing records it.

authored by vienno · committed by vienno · parent a25a641 · Browse files · 1 file+5 added−3 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

1 file+5 added−3 removed

  • other:+5 added−3 removed

1 file+5 added−3 removed

modified:requests/cookies.py+5 added-3 removed
143 unmodified lines
144 clearables = []145 for cookie in cookiejar:146 if cookie.name != name:147 continue148 if domain is None or domain == cookie.domain:149 if path is None or path == cookie.path:150 clearables.append((cookie.domain, cookie.path, cookie.name))148 if domain and domain != cookie.domain:149 continue150 if path and path != cookie.path:151 continue152 clearables.append((cookie.domain, cookie.path, cookie.name))153154 for domain, path, name in clearables:155 cookiejar.clear(domain, path, name)156
329 unmodified lines