backport PR #32732 to 2015.5 fixes #23714 (#32848)

This commit is contained in:
lomeroe 2016-04-26 09:39:53 -05:00 committed by Nicole Thomas
parent 9b5c14c37c
commit edce22a143

View file

@ -3626,7 +3626,8 @@ def copy(
hash1 = salt.utils.get_hash(name)
hash2 = salt.utils.get_hash(source)
if hash1 == hash2:
changed = False
changed = True
ret['comment'] = ' '.join([ret['comment'], '- files are identical but force flag is set'])
if not force:
changed = False
elif not __opts__['test'] and changed: