🐛 Fix afdian webhook
This commit is contained in:
parent
9444913b72
commit
c338512c16
@ -100,11 +100,11 @@ public class SubscriptionService(
|
|||||||
switch (provider)
|
switch (provider)
|
||||||
{
|
{
|
||||||
case "afdian":
|
case "afdian":
|
||||||
var afdianPlans = cfgSection.GetValue<Dictionary<string, string>>("Afdian");
|
// Get the Afdian section first, then bind it to a dictionary
|
||||||
|
var afdianPlans = cfgSection.GetSection("Afdian").Get<Dictionary<string, string>>();
|
||||||
logger.LogInformation("Afdian plans configuration: {Plans}", JsonSerializer.Serialize(afdianPlans));
|
logger.LogInformation("Afdian plans configuration: {Plans}", JsonSerializer.Serialize(afdianPlans));
|
||||||
if (afdianPlans != null && afdianPlans.TryGetValue(subscriptionIdentifier, out var planName))
|
if (afdianPlans != null && afdianPlans.TryGetValue(subscriptionIdentifier, out var planName))
|
||||||
subscriptionIdentifier = planName;
|
subscriptionIdentifier = planName;
|
||||||
|
|
||||||
currency = "cny";
|
currency = "cny";
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user