Using the case statement does not properly notify the file resource about changes

...$content directly to the file resource

Using the case statement does not properly notify the file resource about
changes, leading to unexpected results when generating fragments from Puppet
templates. This patch fixes that issue.