string to MongoId changes

This commit is contained in:
Chomp
2025-07-21 14:52:30 +01:00
parent 0d7b006081
commit 8865484e2b
4 changed files with 8 additions and 8 deletions
@@ -1116,7 +1116,7 @@ public class RagfairController(
/// <param name="offerId">Id of offer to remove</param>
/// <param name="sessionId">Session id of requesting player</param>
/// <returns>ItemEventRouterResponse</returns>
public ItemEventRouterResponse FlagOfferForRemoval(string offerId, MongoId sessionId)
public ItemEventRouterResponse FlagOfferForRemoval(MongoId offerId, MongoId sessionId)
{
var output = eventOutputHolder.GetOutput(sessionId);
@@ -759,7 +759,7 @@ public class RagfairOfferHelper(
* @param sessionId Session id of profile to delete offer from
* @param offerId Id of offer to delete
*/
protected void DeleteOfferById(MongoId sessionId, string offerId)
protected void DeleteOfferById(MongoId sessionId, MongoId offerId)
{
var profileRagfairInfo = profileHelper.GetPmcProfile(sessionId).RagfairInfo;
var offerIndex = profileRagfairInfo.Offers.FindIndex(o => o.Id == offerId);
@@ -99,7 +99,7 @@ public class RagfairServer(
/// Disable/Hide an offer from flea
/// </summary>
/// <param name="offerId"> OfferID to hide </param>
public void HideOffer(string offerId)
public void HideOffer(MongoId offerId)
{
var offers = _ragfairOfferService.GetOffers();
var offer = offers.FirstOrDefault(x => x.Id == offerId);
@@ -119,7 +119,7 @@ public class RagfairServer(
offer.Locked = true;
}
public RagfairOffer? GetOffer(string offerId)
public RagfairOffer? GetOffer(MongoId offerId)
{
return _ragfairOfferService.GetOfferByOfferId(offerId);
}
@@ -22,7 +22,7 @@ public class RagfairTaxService(
)
{
protected readonly Dictionary<
string,
MongoId,
StorePlayerOfferTaxAmountRequestData
> _playerOfferTaxCache = new();
@@ -31,16 +31,16 @@ public class RagfairTaxService(
StorePlayerOfferTaxAmountRequestData offer
)
{
_playerOfferTaxCache[offer.Id] = offer;
_playerOfferTaxCache[offer.Id.Value] = offer;
}
public void ClearStoredOfferTaxById(string offerIdToRemove)
public void ClearStoredOfferTaxById(MongoId offerIdToRemove)
{
_playerOfferTaxCache.Remove(offerIdToRemove);
}
public StorePlayerOfferTaxAmountRequestData GetStoredClientOfferTaxValueById(
string offerIdToGet
MongoId offerIdToGet
)
{
return _playerOfferTaxCache[offerIdToGet];