We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 997f410 commit aea8a24Copy full SHA for aea8a24
lib/puppet/provider/package/snap.rb
@@ -29,13 +29,16 @@ def query
29
end
30
31
def install
32
- current_ensure = query&.get(:ensure)
+ current_ensure = query&.dig(:ensure)
33
current_ensure ||= :absent
34
35
+ Puppet.info(current_ensure)
36
# Refresh the snap if we changed the channel
37
if current_ensure != @resource[:ensure] && current_ensure != :absent
38
+ Puppet.info('modify snap')
39
modify_snap('refresh') # Refresh will switch the channel AND trigger a refresh immediately. TODO Implement switch?
40
else
41
+ Puppet.info('install snap')
42
modify_snap('install')
43
44
0 commit comments