25 Mar
2011
25 Mar
'11
10:15 a.m.
I was looking through the source files just out of curiosity to see how things work and I have a couple of queries. Dancer::Config->load is called twice, first when Dancer::import is called, then again in Dancer::_start. Why is it necessary to call it the second time? And what is the purpose of these lines in Dancer::Config::load? I think that for a key to be in %$SETTINGS, it's hook must already have been called (via _trigger_hooks). So forcing the hooks to be called again like this seems unnecessary to me. 171 foreach my $key (grep { $setters->{$_} } keys %$SETTINGS) { 172 $setters->{$key}->($key, $SETTINGS->{$key}); 173 } Thanks for info and I'm Sorry for poking around in the internals :) Alex