diff --git a/.idea/workspace.xml b/.idea/workspace.xml
index bd2fbd6..6ce3afb 100644
--- a/.idea/workspace.xml
+++ b/.idea/workspace.xml
@@ -4,9 +4,9 @@
-
+
-
+
@@ -153,7 +153,6 @@
-
@@ -178,7 +177,8 @@
-
+
+
true
diff --git a/pkg/internal/services/sign.go b/pkg/internal/services/sign.go
index 2a1a7fd..aa0a17d 100644
--- a/pkg/internal/services/sign.go
+++ b/pkg/internal/services/sign.go
@@ -6,6 +6,7 @@ import (
"git.solsynth.dev/hydrogen/passport/pkg/internal/database"
"git.solsynth.dev/hydrogen/passport/pkg/internal/models"
"gorm.io/gorm"
+ "math"
"math/rand"
"time"
)
@@ -37,7 +38,7 @@ func DailySign(user models.Account) (models.SignRecord, error) {
tier := rand.Intn(5)
record := models.SignRecord{
ResultTier: tier,
- ResultExperience: rand.Intn(tier*100) + 100,
+ ResultExperience: rand.Intn(int(math.Max(float64(tier), 1)*100)+1-100) + 100,
AccountID: user.ID,
}