mirror of
https://github.com/saltstack/salt.git
synced 2025-04-17 10:10:20 +00:00
Merge pull request #30612 from rallytime/bp-29940
Back-port #29940 to 2015.8
This commit is contained in:
commit
ec50581aad
1 changed files with 1 additions and 1 deletions
|
@ -1625,7 +1625,7 @@ def line(path, content, match=None, mode=None, location=None,
|
|||
|
||||
if changed:
|
||||
if show_changes:
|
||||
changes_diff = ''.join(difflib.unified_diff(salt.utils.fopen(path, 'r').readlines(), body.splitlines()))
|
||||
changes_diff = ''.join(difflib.unified_diff(salt.utils.fopen(path, 'r').read().splitlines(), body.splitlines()))
|
||||
fh_ = None
|
||||
try:
|
||||
fh_ = salt.utils.atomicfile.atomic_open(path, 'w')
|
||||
|
|
Loading…
Add table
Reference in a new issue