]> gitweb.fluxo.info Git - puppet-stdlib.git/commit
pw_hash: Fix functionality on JRuby < 1.7.17
authorEli Young <elyscape@gmail.com>
Tue, 5 May 2015 22:16:35 +0000 (15:16 -0700)
committerEli Young <elyscape@gmail.com>
Tue, 5 May 2015 22:53:34 +0000 (15:53 -0700)
commit7d7e905b543448f5d37d13c9e1a03d1e0be307fe
tree433fdf817e8fb29dcaf42a90666aa5a499bbd15a
parent7181e4ebcaf59cb16e7166aa254cbb637590423a
pw_hash: Fix functionality on JRuby < 1.7.17

The previous change to this function broke it on JRuby before 1.7.17 by
attempting to use a variable that wasn't defined (`salt`). To fix this,
define `salt` ahead of time and use that instead of building the salt
later.

cf. https://github.com/puppetlabs/puppetlabs-stdlib/pull/443#discussion_r29718588
lib/puppet/parser/functions/pw_hash.rb