restore missing dict check
Merge pull request #15882 from thatch45/if_fix_ssh

restore missing dict check