public MerchantDetailsItem UpsertValue(string key) { if (!Values.TryGetValue(key, out var value)) { value = new MerchantDetailsItem(); Values.Add(key, value); } return(value); }
private void AddDetailsToMerchantEntry(Dictionary <string, object> merchantEntry, string key, MerchantDetailsItem item) { switch (key) { case "img": { // Use the placed image path instead of the original image url merchantEntry.Add(key, PlacedImageName); } break; default: { merchantEntry.Add(key, item.Value); } break; } }