🐛 Bug fixes on check perm

This commit is contained in:
LittleSheep 2024-11-04 00:55:38 +08:00
parent 3e68cea0d7
commit c0fec10846

View File

@ -44,7 +44,7 @@ func comparePermNode(held any, required any) bool {
if isNumeric(requiredValue) && heldValue.Kind() == reflect.String { if isNumeric(requiredValue) && heldValue.Kind() == reflect.String {
numericValue, _ := strconv.ParseFloat(heldValue.String(), 64) numericValue, _ := strconv.ParseFloat(heldValue.String(), 64)
return toFloat64(requiredValue) >= numericValue return numericValue >= toFloat64(requiredValue)
} }
switch heldValue.Kind() { switch heldValue.Kind() {