Skip to content

Commit 763fb1e

Browse files
fix airnft (#6316)
1 parent 4297d6f commit 763fb1e

File tree

1 file changed

+6
-16
lines changed

1 file changed

+6
-16
lines changed

fees/airnft/index.ts

Lines changed: 6 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
import { FetchOptions, SimpleAdapter } from "../../adapters/types";
22
import { CHAIN } from "../../helpers/chains";
3-
import { METRIC } from "../../helpers/metrics";
43
import coreAssets from "../../helpers/coreAssets.json";
54

65
interface chainData {
@@ -18,8 +17,6 @@ const PURCHASE = 'event Purchase(address indexed previousOwner, address indexed
1817

1918
const fetch = async (options: FetchOptions) => {
2019
const dailyFees = options.createBalances();
21-
const dailyRevenue = options.createBalances();
22-
const dailySupplySideRevenue = options.createBalances();
2320
const { contract, asset } = chainConfig[options.chain]
2421

2522
const logs = await options.getLogs({
@@ -28,16 +25,13 @@ const fetch = async (options: FetchOptions) => {
2825
})
2926
logs.forEach((log) => {
3027
const protocolsCut = log.price / 40n
31-
dailyFees.add(asset, log.price, "NFT Trading Fees")
32-
dailyRevenue.add(asset, protocolsCut, METRIC.SERVICE_FEES)
33-
dailySupplySideRevenue.add(asset, log.price - protocolsCut, "Seller Proceeds")
28+
dailyFees.add(asset, protocolsCut, "NFT Trading Fees")
3429
});
3530

3631
return {
3732
dailyFees,
38-
dailyRevenue,
39-
dailyProtocolRevenue: dailyRevenue,
40-
dailySupplySideRevenue
33+
dailyRevenue: dailyFees,
34+
dailyProtocolRevenue: dailyFees,
4135
}
4236
}
4337

@@ -51,20 +45,16 @@ const adapters: SimpleAdapter = {
5145
[CHAIN.FANTOM]: { start: '2022-02-17'}
5246
},
5347
methodology: {
54-
Fees: "NFT trading fees on all marketplace transactions",
48+
Fees: "2.5% fee on all NFT marketplace transactions",
5549
Revenue: "The protocol takes a 2.5% cut from the seller on all transactions",
5650
ProtocolRevenue: "The protocol takes a 2.5% cut from the seller on all transactions",
57-
SupplySideRevenue: "The remaining sale proceeds paid to NFT creators",
5851
},
5952
breakdownMethodology: {
6053
Fees: {
61-
'NFT Trading Fees': 'Full sale price of NFT marketplace transactions.',
54+
'NFT Trading Fees': '2.5% fee on all NFT marketplace transactions.',
6255
},
6356
Revenue: {
64-
[METRIC.SERVICE_FEES]: '2.5% protocol cut from the seller on all transactions.',
65-
},
66-
SupplySideRevenue: {
67-
"Seller Proceeds": 'The remaining sale proceeds paid to NFT creators.',
57+
'NFT Trading Fees': '2.5% protocol cut from the seller on all transactions.',
6858
},
6959
},
7060
};

0 commit comments

Comments
 (0)