use Readonly; Readonly::Hash our %__DFV_DEFAULTS => { missing_optional_valid => 1, filters => 'trim', msgs => { any_errors => 'err__', prefix => 'err_', format => '%s', } }; sub cgiapp_init { my $self = shift; # Set some defaults for DFV unless they already exist. $self->param('dfv_defaults') || $self->param('dfv_defaults', \ %__DFV_DEFAULTS); return; }