mirror of
https://code.sup39.dev/repos/Wqawg
synced 2024-12-28 23:04:52 +09:00
Rename handleActivity to handleInboxActivity
This commit is contained in:
parent
85c6354291
commit
e36d960d2b
2 changed files with 4 additions and 4 deletions
|
@ -14,7 +14,7 @@
|
||||||
-}
|
-}
|
||||||
|
|
||||||
module Vervis.Federation
|
module Vervis.Federation
|
||||||
( handleActivity
|
( handleInboxActivity
|
||||||
)
|
)
|
||||||
where
|
where
|
||||||
|
|
||||||
|
@ -52,8 +52,8 @@ import Vervis.Settings
|
||||||
-- | Handle an activity that came to our inbox. Return a description of what we
|
-- | Handle an activity that came to our inbox. Return a description of what we
|
||||||
-- did, and whether we stored the activity or not (so that we can decide
|
-- did, and whether we stored the activity or not (so that we can decide
|
||||||
-- whether to log it for debugging).
|
-- whether to log it for debugging).
|
||||||
handleActivity :: Object -> Text -> InstanceId -> RemoteSharerId -> Activity -> Handler (Text, Bool)
|
handleInboxActivity :: Object -> Text -> InstanceId -> RemoteSharerId -> Activity -> Handler (Text, Bool)
|
||||||
handleActivity raw hActor iidActor rsidActor (Activity _id _luActor audience specific) =
|
handleInboxActivity raw hActor iidActor rsidActor (Activity _id _luActor audience specific) =
|
||||||
case specific of
|
case specific of
|
||||||
CreateActivity (Create note) -> do
|
CreateActivity (Create note) -> do
|
||||||
result <- runExceptT $ handleCreate iidActor hActor rsidActor raw audience note
|
result <- runExceptT $ handleCreate iidActor hActor rsidActor raw audience note
|
||||||
|
|
|
@ -134,7 +134,7 @@ postInboxR = do
|
||||||
case r of
|
case r of
|
||||||
Right (ct, (WithValue raw d@(Doc h a), (iid, rsid))) ->
|
Right (ct, (WithValue raw d@(Doc h a), (iid, rsid))) ->
|
||||||
forkHandler (handleWorkerError now ct d) $ do
|
forkHandler (handleWorkerError now ct d) $ do
|
||||||
(msg, stored) <- handleActivity raw h iid rsid a
|
(msg, stored) <- handleInboxActivity raw h iid rsid a
|
||||||
if stored
|
if stored
|
||||||
then recordUsed now msg
|
then recordUsed now msg
|
||||||
else recordUnused now ct d msg
|
else recordUnused now ct d msg
|
||||||
|
|
Loading…
Reference in a new issue