Pug has asked for the wisdom of the Perl Monks concerning the following question: ⭐ (subroutines)
I'm using IniConf which returns undefined if the section
does not exist. I have found that this works but it is
painful to read:
Is there a better way?if ( ! my $temp = $cfg->val("MISC","HASHTYPE") ) { $CONFIG{HASHTYPE}="sha1"; } else { $CONFIG{HASHTYPE}=$temp; }
Originally posted as a Categorized Question.
Back to
Seekers of Perl Wisdom