A decentralized music tracking and discovery platform built on AT Protocol 🎵

feat: migrate to Bun and update dependencies for improved performance

+9 -9
+2 -2
apps/api/package.json
··· 24 24 "prod:all": "concurrently 'tsx ./src/index.ts' 'tsx ./src/server.ts'", 25 25 "format": "biome format src", 26 26 "lint": "biome lint src", 27 - "feed": "tsx ./src/scripts/feed.ts", 28 - "dedup": "tsx ./src/scripts/dedup.ts" 27 + "feed": "bun ./src/scripts/feed.ts", 28 + "dedup": "bun ./src/scripts/dedup.ts" 29 29 }, 30 30 "dependencies": { 31 31 "@atproto/api": "^0.13.31",
+3 -3
apps/api/src/index.ts
··· 47 47 rateLimiter({ 48 48 limit: 1000, 49 49 window: 30, // 👈 30 seconds 50 - }), 50 + }) 51 51 ); 52 52 53 53 app.use("*", async (c, next) => { ··· 162 162 ctx.redis.get(`nowplaying:${user.did}:status`), 163 163 ]); 164 164 return c.json( 165 - nowPlaying ? { ...JSON.parse(nowPlaying), is_playing: status === "1" } : {}, 165 + nowPlaying ? { ...JSON.parse(nowPlaying), is_playing: status === "1" } : {} 166 166 ); 167 167 }); 168 168 ··· 314 314 listeners: 1, 315 315 sha256: item.track.sha256, 316 316 id: item.scrobble.id, 317 - })), 317 + })) 318 318 ); 319 319 }); 320 320
+4 -4
apps/api/src/sqliteKv.ts
··· 100 100 oc.column("id").doUpdateSet({ 101 101 value, 102 102 updated_at: now, 103 - }), 103 + }) 104 104 ) 105 105 .execute(); 106 106 }, ··· 125 125 oc.column("id").doUpdateSet({ 126 126 value, 127 127 updated_at: now, 128 - }), 128 + }) 129 129 ) 130 130 .execute(); 131 - }), 131 + }) 132 132 ); 133 133 }); 134 134 }, ··· 169 169 await getDb().destroy(); 170 170 }, 171 171 }; 172 - }, 172 + } 173 173 );