mirror of
https://github.com/google/nomulus.git
synced 2025-05-14 16:37:13 +02:00
Set domain create fee cost to be 0 for anchor tenants
We already properly remove EAP fees for anchor tenants. ------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=235529469
This commit is contained in:
parent
53cda35265
commit
4d9db4ac8c
2 changed files with 14 additions and 10 deletions
|
@ -31,6 +31,7 @@ import google.registry.model.domain.fee.BaseFee;
|
|||
import google.registry.model.domain.fee.BaseFee.FeeType;
|
||||
import google.registry.model.domain.fee.Fee;
|
||||
import google.registry.model.registry.Registry;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Optional;
|
||||
import javax.inject.Inject;
|
||||
import org.joda.money.CurrencyUnit;
|
||||
|
@ -56,9 +57,10 @@ public final class DomainPricingLogic {
|
|||
throws EppException {
|
||||
CurrencyUnit currency = registry.getCurrency();
|
||||
|
||||
// Get the vanilla create cost.
|
||||
BaseFee createFeeOrCredit =
|
||||
Fee.create(getDomainCreateCost(domainName, date, years).getAmount(), FeeType.CREATE);
|
||||
// Get the vanilla create cost, or 0 for anchor tenants.
|
||||
BigDecimal domainCreateCost =
|
||||
isAnchorTenant ? BigDecimal.ZERO : getDomainCreateCost(domainName, date, years).getAmount();
|
||||
BaseFee createFeeOrCredit = Fee.create(domainCreateCost, FeeType.CREATE);
|
||||
|
||||
// Create fees for the cost and the EAP fee, if any.
|
||||
Fee eapFee = registry.getEapFeeFor(date);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue