remove dead code
check if targeted pane actually exists