func (l *Logger) HasListeners(flag string) bool {
	l.Lock()
	defer l.Unlock()

	if l.Listeners == nil {
		return false
	}
	listeners, ok := l.Listeners[flag]
	if !ok {
		return false
	}
	return len(listeners) > 0
}
// HasListeners returns if there are registered listener for an event.
HasListeners returns if there are registered listener for an event.
// HasListeners returns if there are registered listener for an event .
func (l *Logger) HasListeners(flag string) bool {
	l.Lock()
	defer l.Unlock()
	if l.Listeners == nil {
		return false
	}
	listeners, ok := l.Listeners[flag]
	if !ok {
		return false
	}
	return len(listeners) > 0
}
func ( l * Logger ) HasListeners ( flag string ) bool { l . Lock ( ) defer l . Unlock ( ) if l . Listeners == nil { return false } listeners , ok := l . Listeners [ flag ] if ! ok { return false } return len ( listeners ) > 0 }
HasListeners returns if there are registered listener for an event.
HasListeners returns if there are registered listener for an event .