Fixes #4489 - Use digest instead of mtime for file comparison

Fixes #4489 - Use digest instead of mtime for file comparison