mirror of
https://github.com/aljazceru/ditto.git
synced 2025-12-18 14:04:23 +01:00
refactor(zap split): rename amount to weight
This commit is contained in:
@@ -183,8 +183,8 @@ const createStatusController: AppController = async (c) => {
|
||||
if (lnurl && zap_split) {
|
||||
let totalSplit = 0;
|
||||
for (const pubkey in zap_split) {
|
||||
totalSplit += zap_split[pubkey].amount;
|
||||
tags.push(['zap', pubkey, Conf.relay, zap_split[pubkey].amount.toString()]);
|
||||
totalSplit += zap_split[pubkey].weight;
|
||||
tags.push(['zap', pubkey, Conf.relay, zap_split[pubkey].weight.toString()]);
|
||||
}
|
||||
if (totalSplit) {
|
||||
tags.push(['zap', author?.pubkey as string, Conf.relay, Math.max(0, 100 - totalSplit).toString()]);
|
||||
|
||||
Reference in New Issue
Block a user