Please add a comment as to why this works, what button.children[0] is and why/if `len(button.children) > 1` is always true.