Fix template not showing a diff with a directory
Fix template not showing a diff with a directory

Template can take a directory as the destination.  When that's the case,
we need to diff between the source and the file inside of the directory.
That happened when the directory was specified with a trailing slash but
not when it was specified on its own.  This change fixes that.

Fixes #24413

thaim/ansible,thaim/ansible