Clean up Session::Privilege code.

Add $! to errorHandler message in Session::Icon when toolbar dir cannot be opened.
Change i18n for default toolbar "Default" to be more self explanatory.
This commit is contained in:
Colin Kuskie 2006-10-19 23:19:22 +00:00
parent 052d0ddb15
commit 37aad09679
3 changed files with 5 additions and 9 deletions

View file

@ -258,7 +258,7 @@ sub getToolbarOptions {
my $self = shift;
$options{useLanguageDefault} = WebGUI::International->new($self->session,'WebGUI')->get(1084);
my $dir = $self->session->config->get("extrasPath")."/toolbar";
opendir (DIR,$dir) or $self->session->errorHandler->warn("Can't open toolbar directory!");
opendir (DIR,$dir) or $self->session->errorHandler->warn("Can't open toolbar directory!: $!");
my @files = readdir(DIR);
foreach my $file (@files) {
if (substr($file,0,1) ne ".") {