You will find, that ssh , when executed as a securified rexec -replacement, returns the error code of the remotely executed program.
You could, therefore, equally try the likes of:
if ! ssh "${user}@${host}" "ls /dir/in/question >/dev/null 2>&1" ; then
echo "dir does not exist"
else
echo "dir does exist"
fi
Which would not be of much use in your context (it would i.e. produce false positives if "/dir/in/question" would be a file) but you can use this mechanism to generally execute commands remotely while testing for their return code - UNIX convention is to return 0 on success and something else for the various reasons of being unsuccessful.