Refactored variable name from

DalleGenerationImageAmountRatios to
DalleGenerationImageAmounts
This commit is contained in:
ckt1031
2023-11-15 20:13:48 +08:00
parent 6f5655ec7a
commit 29fbd12870
2 changed files with 4 additions and 4 deletions

View File

@@ -15,12 +15,12 @@ import (
)
func isWithinRange(element string, value int) bool {
if _, ok := common.DalleGenerationImageAmountRatios[element]; !ok {
if _, ok := common.DalleGenerationImageAmounts[element]; !ok {
return false
}
min := common.DalleGenerationImageAmountRatios[element][0]
max := common.DalleGenerationImageAmountRatios[element][1]
min := common.DalleGenerationImageAmounts[element][0]
max := common.DalleGenerationImageAmounts[element][1]
return value >= min && value <= max
}