public static function userCanOnLogs( $log , $action , $value , $username = null)
	{
		if ( is_null( $username ) ) $username = self::getCurrentUsername();
		if ( is_null( $username ) ) return false;
		if ( ! self::userExists( $username ) ) return false;
		if ( in_array( 'admin' , self::$auth['users'][ $username ]['roles'] ) ) return true;
		if ( ! isset( self::$auth['users'][ $username ]['logs'][ $log ][ $action ] ) ) return false;
		return ( self::$auth['users'][ $username ]['logs'][ $log ][ $action ] === $value );
	}
public static function userCanOnLogs( $log , $action , $value , $username = null)
	{
		if ( is_null( $username ) ) $username = self::getCurrentUsername();
		if ( is_null( $username ) ) return false;
		if ( ! self::userExists( $username ) ) return false;
		if ( in_array( 'admin' , self::$auth['users'][ $username ]['roles'] ) ) return true;
		if ( ! isset( self::$auth['users'][ $username ]['logs'][ $log ][ $action ] ) ) return false;
		return ( self::$auth['users'][ $username ]['logs'][ $log ][ $action ] === $value );
	}
public static function userCanOnLogs ( $ log , $ action , $ value , $ username = null ) { if ( is_null ( $ username ) ) $ username = self :: getCurrentUsername ( ) ; if ( is_null ( $ username ) ) return false ; if ( ! self :: userExists ( $ username ) ) return false ; if ( in_array ( 'admin' , self :: $ auth [ 'users' ] [ $ username ] [ 'roles' ] ) ) return true ; if ( ! isset ( self :: $ auth [ 'users' ] [ $ username ] [ 'logs' ] [ $ log ] [ $ action ] ) ) return false ; return ( self :: $ auth [ 'users' ] [ $ username ] [ 'logs' ] [ $ log ] [ $ action ] === $ value ) ; }
Tell if a user has an access on a log file

@param   string  $log       the fileid
@param   string  $action    the name of the action
@param   string  $value     the value for this action
@param   string  $username  the username

@return  boolean
Tell if a user has an access on a log file