自动捕获异常

前置条件

import (
    "github.com/qqingdou/message-notify-go/messagenotify"
)

在抛出的异常代码前,放置以下代码捕获异常

defer messagenotify.AutoCatchException()

panic("Hello World, I'm a error.")

results matching ""

    No results matching ""