Skip to content

Commit 98e4825

Browse files
committed
fixed logic bug
1 parent b387e6d commit 98e4825

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

log/log.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ Can be sussy if not used properly and by passing in random codes.
4747
Only use when you have SetLog().
4848
*/
4949
func LogNonFatal_C(code int, msg string) {
50-
if validateCode(code) {
50+
if !validateCode(code) {
5151
LogNonFatal("log.go", "LogNonFatal_C()", "Entered Invalid Code. Returning False automacially")
5252
return
5353
}
@@ -62,7 +62,7 @@ Can be sussy if not used properly and by passing in random codes.
6262
Only use when you have SetLog().
6363
*/
6464
func LogNonFatalError_C(code int, msg string, err error) bool {
65-
if code < 0 || code >= len(logPaths) {
65+
if !validateCode(code) {
6666
LogNonFatal("log.go", "LogNonFatalError_C()", "Entered Invalid Code. Returning False automacially")
6767
return false
6868
}

0 commit comments

Comments
 (0)