summaryrefslogtreecommitdiff
path: root/lib/puppet_x
diff options
context:
space:
mode:
authorHelen <helen@puppetlabs.com>2016-10-07 14:13:51 +0100
committerGitHub <noreply@github.com>2016-10-07 14:13:51 +0100
commitdb8edf5cb36e038c747d177914aaa747c770477d (patch)
tree307e89f4aafe8563b854eb1e9266337246a39406 /lib/puppet_x
parente7825bc9dd0c33c986fcdc5e6dfd11c6cded8ca1 (diff)
parentddae9880025b6dfdc3b5a8c177548c8eb5e50a91 (diff)
Merge pull request #667 from DavidS/remove-dynamic-deprecation_gen
(FM-5703, PUP-6717) Remove the dynamic deprecation_gen function
Diffstat (limited to 'lib/puppet_x')
-rw-r--r--lib/puppet_x/puppetlabs/stdlib/deprecation_gen.rb19
1 files changed, 0 insertions, 19 deletions
diff --git a/lib/puppet_x/puppetlabs/stdlib/deprecation_gen.rb b/lib/puppet_x/puppetlabs/stdlib/deprecation_gen.rb
deleted file mode 100644
index 0d8908d..0000000
--- a/lib/puppet_x/puppetlabs/stdlib/deprecation_gen.rb
+++ /dev/null
@@ -1,19 +0,0 @@
-# Creates a Puppet 4 function for the corresponding puppet 3 validate function, who's name will be passed as an argument, alongside the type for deprecation output purposes.
-module PuppetX
- module Puppetlabs
- module Stdlib
- def self.deprecation_gen(funct, type)
- Puppet::Functions.create_function(funct, Puppet::Functions::InternalFunction) do
- dispatch :deprecation_gen do
- scope_param
- optional_repeated_param 'Any', :args
- end
- define_method 'deprecation_gen' do |scope, *args|
- call_function('deprecation', 'puppet_3_type_check', "This method is deprecated, please use the stdlib validate_legacy function, with #{type}. There is further documentation for validate_legacy function in the README.")
- scope.send("function_#{funct}", args)
- end
- end
- end
- end
- end
-end