This commit is contained in:
richboo111
2023-03-17 15:31:21 +08:00
parent 7307e5c900
commit 2cfb402276

View File

@@ -2,6 +2,7 @@ package xpyun
import (
"fmt"
"strings"
"time"
"git.rosy.net.cn/baseapi/utils"
@@ -78,6 +79,9 @@ func (c *PrinterHandler) RegisterPrinter(ctx *jxcontext.Context, sn, id2, printe
if globals.EnableStoreWrite {
err = api.XpyunAPI.AddPrinters(sn, printerName)
}
if strings.Contains(err.Error(), "打印机已存在") {
return "", "", nil
}
return "", "", err
}