errhandler

package
v0.0.0-...-f5ef94b Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 11, 2021 License: MIT Imports: 9 Imported by: 0

Documentation

Overview

Package errhandler provides the default error handlers.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CommandError

func CommandError() func(error, *plugin.Context)

CommandError returns the logger function used for errors.Log. It logs the error using the passed *zap.SugaredLogger, and extracts the assigned *sentry.Hub and *zap.SugaredLogger from the context using sentryadam.GetHub.

func Gateway

func Gateway(l *zap.SugaredLogger, h *sentry.Hub) func(error)

Gateway returns the error handler function used for the bot.Options.GatwayErrorHandler.

func StateError

func StateError(l *zap.SugaredLogger, h *sentry.Hub) func(error)

StateError returns the logger function used for the bot.Option.StateErrorHandler.

func StatePanic

func StatePanic(l *zap.SugaredLogger, h *sentry.Hub) func(interface{})

StatePanic returns the logger function used for the bot.Option.StatePanicHandler.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL