Skip to content

Commit 74fcd09

Browse files
committed
fix: simplify children function
Signed-off-by: Henry Schreiner <[email protected]>
1 parent 45c661b commit 74fcd09

File tree

1 file changed

+1
-8
lines changed

1 file changed

+1
-8
lines changed

src/uproot_browser/tree.py

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -57,14 +57,7 @@ def _(item: uproot.behaviors.TBranch.HasBranches) -> bool:
5757
return len(item.branches) > 0
5858

5959

60-
@functools.singledispatch
61-
def get_children(item: Any) -> set[str]: # noqa: ARG001
62-
msg = "Should not be called, protect with is_dir!"
63-
raise AssertionError(msg)
64-
65-
66-
@get_children.register
67-
def _(item: Mapping[str, Any]) -> set[str]:
60+
def get_children(item: Mapping[str, Any]) -> set[str]:
6861
return {
6962
key.split(";")[0]
7063
for key in item.keys() # noqa: SIM118

0 commit comments

Comments
 (0)