issue #19807: Fix behavior of copy address button

DO NOT PULL UNTIL 1.3.1 is tagged.