Fixed another NPE that could arise due to ordering operations on focus handling