From: pdbogen Date: Wed, 29 Aug 2007 21:13:20 +0000 (+0000) Subject: Load access levels independently of users X-Git-Url: http://git.mmlx.us/?a=commitdiff_plain;h=32f68a6ecc3af222dd0c67c081902917d449f1c5;p=destult.git Load access levels independently of users git-svn-id: https://www.cernu.us/~pdbogen/svn/destult2@4 088b83a4-0077-4247-935c-42ec02c2848b --- diff --git a/core.pl b/core.pl index e1093ae..a5cc58d 100644 --- a/core.pl +++ b/core.pl @@ -65,13 +65,18 @@ sub on_start { print( "CORE: No factoids found.\n" ); } - if( -e "privs.yaml" && -e "access.yaml" ) { - $heap->{ 'privs' } = \%{ LoadFile( "privs.yaml" ) }; + if( -e "access.yaml" ) { $heap->{ 'access' } = \%{ LoadFile( "access.yaml" ) }; + print( "CORE: Access levels loaded.\n" ); + } else { + $heap->{ 'access' } = { }; + } + + if( -e "privs.yaml" ) { + $heap->{ 'privs' } = \%{ LoadFile( "privs.yaml" ) }; print( "CORE: Users loaded.\n" ); } else { $heap->{ 'privs' } = { }; - $heap->{ 'access' } = { }; print( "CORE: No users found.\n" ); }