Commit 2486aae
committed
Restructure transport.lookup to avoid spurious mypy error
lookup() accepts None also, because it is intended to return the default.
dict.get() obviously accepts None, because it will not be
present and thus return the default. Apparently mypy wants
to be stricter than that.
Just restructure to be a bit plainer.1 parent 924db0a commit 2486aae
1 file changed
+5
-4
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
11 | 11 | | |
12 | 12 | | |
13 | 13 | | |
14 | | - | |
| 14 | + | |
15 | 15 | | |
16 | | - | |
17 | | - | |
18 | | - | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
19 | 20 | | |
20 | 21 | | |
21 | 22 | | |
| |||
0 commit comments