fixing model

This commit is contained in:
afeiszli
2021-09-18 11:01:34 -04:00
parent 74b15a6a13
commit b828f7b6d9
8 changed files with 48 additions and 21 deletions

View File

@@ -1,6 +1,7 @@
package netclientutils
import (
"crypto/tls"
"errors"
"fmt"
"io/ioutil"
@@ -13,11 +14,11 @@ import (
"strconv"
"strings"
"time"
"crypto/tls"
"google.golang.org/grpc"
"google.golang.org/grpc/credentials"
"golang.zx2c4.com/wireguard/wgctrl"
"golang.zx2c4.com/wireguard/wgctrl/wgtypes"
"google.golang.org/grpc"
"google.golang.org/grpc/credentials"
)
const NO_DB_RECORD = "no result found"
@@ -37,6 +38,14 @@ func IsWindows() bool {
return runtime.GOOS == "windows"
}
func IsMac() bool {
return runtime.GOOS == "macos"
}
func IsLinux() bool {
return runtime.GOOS == "linux"
}
// == database returned nothing error ==
func IsEmptyRecord(err error) bool {
if err == nil {