From 817a4023fb4fc4df238f9cf02531f139232bdff4 Mon Sep 17 00:00:00 2001 From: Anton Dyudin Date: Wed, 12 Oct 2016 14:53:55 -0700 Subject: [PATCH] remove referral tracking --- gen/hood/invite.hoon | 6 +++--- lib/womb.hoon | 38 ++++---------------------------------- 2 files changed, 7 insertions(+), 37 deletions(-) diff --git a/gen/hood/invite.hoon b/gen/hood/invite.hoon index b89f93866..582d4b5fa 100644 --- a/gen/hood/invite.hoon +++ b/gen/hood/invite.hoon @@ -8,9 +8,9 @@ /+ womb :- %say |= $: {now/@da eny/@uvJ bec/beak} - {{who/@t $~} ref/(unit (each ship mail:womb)) sta/@} + {{who/@t $~} sta/@} == :- %womb-invite -^- {cord reference invite}:womb +^- {cord invite}:womb =+ inv=(scot %uv (end 7 1 eny)) -[inv ref [who 10 sta "You have been invited to Urbit: {(trip inv)}" "This is an invite of 10 planets"]] +[inv [who 10 sta "You have been invited to Urbit: {(trip inv)}" "This is an invite of 10 planets"]] diff --git a/lib/womb.hoon b/lib/womb.hoon index 4ca51a57c..8880796a9 100644 --- a/lib/womb.hoon +++ b/lib/womb.hoon @@ -56,10 +56,6 @@ owner/mail :: owner's email history/(list mail) :: transfer history == :: -++ client :: per email - $: sta/@ud :: unused star refs - has/(set @p) :: planets owned - == :: ++ property :: subdivided plots $: galaxies/(map @p galaxy) :: galaxy planets/(map @p planet) :: star @@ -75,10 +71,6 @@ $: intro/tape :: in invite email hello/tape :: as talk message == :: -++ reference :: affiliate credit - (unit (each @p mail)) :: ship or email -:: :: -++ reference-rate 2 :: star refs per star ++ stat (pair live dist) :: external info ++ live ?($cold $seen $live) :: online status ++ dist :: allocation @@ -102,7 +94,7 @@ $: boss/(unit ship) :: outside master bureau/(map passhash balance) :: active invitations office/property :: properties managed - hotel/(map (each ship mail) client) :: everyone we know + hotel/(jug mail ship) :: everyone we know recycling/(map ship @) :: old ticket keys == :: -- :: @@ -143,7 +135,7 @@ {$claim aut/passcode her/@p} {$recycle who/mail him/knot tik/knot} {$bonus tid/cord pla/@ud sta/@ud} - {$invite tid/cord ref/reference inv/invite} + {$invite tid/cord inv/invite} {$reinvite aut/passcode inv/invite} == -- @@ -629,15 +621,9 @@ == :: ++ poke-invite :: create invitation - |= {tid/cord ref/reference inv/invite} + |= {tid/cord inv/invite} =< abet =. log-transaction (log-transaction %invite +<) - =. hotel - ?~ ref hotel - ?~ sta.inv hotel - %+ ~(put by hotel) u.ref - =+ cli=(fall (~(get by hotel) u.ref) *client) - cli(sta +(sta.cli)) (invite-from ~ tid inv) :: ++ invite-from :: traced invitation @@ -693,15 +679,6 @@ ?> =(src src) :: self-authenticated (emit %knew /report her wyl) :: -++ use-reference :: bonus stars - |= a/(each @p mail) ^- (unit _+>) - ?. (~(has by hotel) a) ~ - =+ cli=(~(get by hotel) a) - ?~ cli ~ - ?. (gte sta.u.cli reference-rate) ~ - =. sta.u.cli (sub sta.u.cli reference-rate) - `+>.$(hotel (~(put by hotel) a u.cli)) -:: ++ poke-do-ticket :: issue child ticket |= her/ship =< abet @@ -765,10 +742,6 @@ ?+ (clan her) ~|(bad-size+(clan her) !!) $king =; all (claim-star.all owner.bal her) - =+ (use-reference &+src) - ?^ - u :: prefer using references - =+ (use-reference |+owner.bal) - ?^ - u =. stars.bal ~|(%no-stars (dec stars.bal)) +>.$(bureau (~(put by bureau) (shaf %pass aut) bal)) :: @@ -787,10 +760,7 @@ :: ++ claim-planet :: register |= {who/mail her/@p} ^+ +> - =. hotel - %+ ~(put by hotel) |+who - =+ cli=(fall (~(get by hotel) |+who) *client) - cli(has (~(put in has.cli) her)) + =. hotel (~(put ju hotel) who her) %+ mod-managed-planet her |= a/planet ^- planet ?^ a ~|(impure-planet+[her ?:(-.u.a %owned %split)] !!)