rm commented code
This commit is contained in:
parent
c46f5ee1eb
commit
a3a569013e
|
@ -46,32 +46,6 @@ export const handleInboxPost = async (req: Request) => {
|
|||
finally { }
|
||||
};
|
||||
|
||||
/*
|
||||
export const sendActivity = async (publicKeyId: string, privateKey: string, activity: string, hash: string, inbox: string) => {
|
||||
const headers: Record<string, string> = {
|
||||
date: new Date().toUTCString(),
|
||||
digest: hash,
|
||||
host: new URL(inbox).host,
|
||||
"content-type": `application/ld+json; profile="${CONTEXT}"`
|
||||
};
|
||||
|
||||
const signer = new Sha256Signer({ privateKey, publicKeyId });
|
||||
const signature = signer.sign({
|
||||
url: inbox,
|
||||
method: "POST",
|
||||
headers: flattenHeaders(headers)
|
||||
});
|
||||
|
||||
headers.signature = signature;
|
||||
|
||||
return fetch(inbox, {
|
||||
method: "POST",
|
||||
headers,
|
||||
body: activity
|
||||
});
|
||||
};
|
||||
*/
|
||||
|
||||
export const deleteArticleActivity = (article: Article, user: User) => {
|
||||
const actor = fillRoute("actor", user.nickname);
|
||||
const published = typeof article.updated_at === "number" ? new Date(article.updated_at) : article.updated_at;
|
||||
|
|
Loading…
Reference in New Issue