Skip to content

Commit 0001566

Browse files
authored
Merge pull request #786 from reidmv/MODULES-5113
(MODULES-5113) Make line support Sensitive
2 parents 4a980fc + ec6cd56 commit 0001566

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

lib/puppet/type/file_line.rb

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -104,8 +104,16 @@
104104
' This is also takes a regex.'
105105
end
106106

107-
newparam(:line) do
107+
# The line property never changes; the type only ever performs a create() or
108+
# destroy(). line is a property in order to allow it to correctly handle
109+
# Sensitive type values. Because it is a property which will never change,
110+
# it should never be considered out of sync.
111+
newproperty(:line) do
108112
desc 'The line to be appended to the file or used to replace matches found by the match attribute.'
113+
114+
def retrieve
115+
@resource[:line]
116+
end
109117
end
110118

111119
newparam(:path) do

0 commit comments

Comments
 (0)