Fixed broken force=yes on files for directories

If you try to overwrite a directory with a symlink using file and force=yes, you are presented with the error: "msg: refusing to convert between directory and link for...". This is not the expected behavior according to the documentation.

This fix simply adds a check for whether the previous state is a directory, restoring full functionality for the force option.