Fixed undefined error in menu sub if sanitized information is empty. (hopefully)
This commit is contained in:
bluesaxman 2019-09-05 07:51:03 -06:00
parent 43b1766192
commit 44e6734a1a

View File

@ -205,7 +205,7 @@ sub render_menu {
} }
sub menu { sub menu {
my $current_page = (split("/",shift))[1]; my $current_page = (split("/",(shift or "/home")))[1];
$current_page =~ s/_dir$//g; $current_page =~ s/_dir$//g;
my %menus = (); my %menus = ();
# Handle main menu # Handle main menu