aboutsummaryrefslogtreecommitdiff
path: root/src/routes/api/mastodon.json/+server.ts
diff options
context:
space:
mode:
authornetop://ウィビ <paul@webb.page>2026-04-28 09:52:38 -0700
committernetop://ウィビ <paul@webb.page>2026-04-28 09:52:38 -0700
commitecafa83e14045ebda8a00b251ab62cfc2d7f3012 (patch)
tree69d3b9bbcaffe82ae7911c33a904d855f41fad22 /src/routes/api/mastodon.json/+server.ts
parent7f14dc601901d4b4494ccb97f43fc93285d0922a (diff)
downloadhomepage-ecafa83e14045ebda8a00b251ab62cfc2d7f3012.tar.gz
homepage-ecafa83e14045ebda8a00b251ab62cfc2d7f3012.zip
2026.04.28HEADprimary
- updates deps - updates about, forgot i had a typo - updates blog panel - fixes type issues across a few files - updates uchu link
Diffstat (limited to 'src/routes/api/mastodon.json/+server.ts')
-rw-r--r--src/routes/api/mastodon.json/+server.ts4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/routes/api/mastodon.json/+server.ts b/src/routes/api/mastodon.json/+server.ts
index 72cbd38..f14f726 100644
--- a/src/routes/api/mastodon.json/+server.ts
+++ b/src/routes/api/mastodon.json/+server.ts
@@ -31,8 +31,8 @@ export const POST = async({ fetch }) => {
/*** HELPER ------------------------------------------- ***/
-function findCreateType(arr: Array<{ [key: string]: any }>): { [key: string]: any } | undefined {
- return arr.find(obj => obj.type === "Create");
+function findCreateType(arr: Array<{ [key: string]: any }>): { [key: string]: any; } {
+ return arr.find(obj => obj.type === "Create") || {};
}
function processAttachments(attachments: Array<{ [key: string]: any }>): Array<string> {