focusElement undefined resulted in null error