diff --git a/src/apps/haikudepot/model/WebAppInterface.cpp b/src/apps/haikudepot/model/WebAppInterface.cpp index 0fb21f42df..39b7b83aa0 100644 --- a/src/apps/haikudepot/model/WebAppInterface.cpp +++ b/src/apps/haikudepot/model/WebAppInterface.cpp @@ -471,7 +471,7 @@ WebAppInterface::CreateUserRating(const BString& packageName, .AddValue("pkgVersionType", "LATEST") .AddValue("userNickname", fUsername) .AddValue("rating", rating) - .AddValue("userRatingStabilityCode", stability) + .AddValue("userRatingStabilityCode", stability, true) .AddValue("comment", comment) .AddValue("naturalLanguageCode", languageCode) .EndObject() @@ -496,7 +496,7 @@ WebAppInterface::UpdateUserRating(const BString& ratingID, .AddObject() .AddValue("code", ratingID) .AddValue("rating", rating) - .AddValue("userRatingStabilityCode", stability) + .AddValue("userRatingStabilityCode", stability, true) .AddValue("comment", comment) .AddValue("naturalLanguageCode", languageCode) .AddValue("active", active) diff --git a/src/apps/haikudepot/ui/RatePackageWindow.cpp b/src/apps/haikudepot/ui/RatePackageWindow.cpp index 2f7b908b13..f9b118d89b 100644 --- a/src/apps/haikudepot/ui/RatePackageWindow.cpp +++ b/src/apps/haikudepot/ui/RatePackageWindow.cpp @@ -427,7 +427,7 @@ RatePackageWindow::_QueryRatingThread() } if (result.FindString("userRatingStabilityCode", &fStability) == B_OK) { - int32 index = -1; + int32 index = 0; for (int32 i = fStabilityCodes.CountItems() - 1; i >= 0; i--) { const StabilityRating& stability = fStabilityCodes.ItemAtFast(i); @@ -493,6 +493,9 @@ RatePackageWindow::_SendRatingThread() Unlock(); + if (stability == "unspecified") + stability = ""; + status_t status; BMessage info; if (ratingID.Length() > 0) {