These 5 lines could be moved into `ShellDeleteFileOrDirectory()` since they are duplicated in both places that call the function.