diff --git a/mixins/Rating.pixy b/mixins/Rating.pixy index d9479160..775f6a82 100644 --- a/mixins/Rating.pixy +++ b/mixins/Rating.pixy @@ -1,2 +1,5 @@ component Rating(value float64, user *arn.User) - .anime-rating= fmt.Sprintf("%." + strconv.Itoa(user.Settings().Format.RatingsPrecision) + "f", value) \ No newline at end of file + if user == nil + .anime-rating= fmt.Sprintf("%.1f", value) + else + .anime-rating= fmt.Sprintf("%." + strconv.Itoa(user.Settings().Format.RatingsPrecision) + "f", value) \ No newline at end of file