Skip to content

Commit 38a9a85

Browse files
committed
chore: cleanup
1 parent 0dcd69e commit 38a9a85

File tree

13 files changed

+202
-206
lines changed

13 files changed

+202
-206
lines changed

.dockerignore

+1-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,4 @@
11
node_modules
2-
.yarn/cache/
3-
.yarn/build-state.yml
4-
.yarn/install-state.gz
2+
.yarn
53

64
packages/server/dist

.gitignore

-5
Original file line numberDiff line numberDiff line change
@@ -249,11 +249,6 @@ modules.xml
249249
# Yarn 2
250250
.yarn/*
251251
!.yarn/patches
252-
!.yarn/releases
253-
!.yarn/plugins
254-
!.yarn/sdks
255-
!.yarn/versions
256-
.pnp.*
257252

258253
# Env
259254
*.env

packages/server/Dockerfile

+3-4
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,12 @@ FROM base AS deps
77
WORKDIR /app
88

99
# Copy yarn data
10-
COPY .yarn/ ./.yarn/
1110
COPY .yarnrc.yml ./
1211
COPY yarn.lock package.json ./
1312

1413
# Copy package.jsons of all related packages
1514
COPY packages/server/package.json ./packages/server/
15+
COPY packages/server/prisma ./packages/server/prisma
1616

1717
# Install dependencies for the workspace
1818
WORKDIR /app/packages/server
@@ -27,12 +27,11 @@ COPY --from=deps /app/packages/server /app/packages/server
2727
COPY --from=deps /app/node_modules /app/node_modules
2828

2929
# Copy dependency information and source, then build
30-
COPY yarn.lock .
31-
COPY package.json .
30+
COPY yarn.lock package.json .yarnrc.yml .
3231
COPY packages/server /app/packages/server
3332
WORKDIR /app/packages/server
3433

35-
RUN yarn prisma generate && yarn build
34+
RUN yarn build
3635

3736
# Build the actual running server
3837
FROM base

packages/server/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@
2626
"@koa/cors": "^5.0.0",
2727
"@koa/router": "13.1.0",
2828
"@prisma/client": "5.20.0",
29-
"discord.js": "14.16.2",
29+
"discord.js": "14.16.3",
3030
"dotenv": "16.4.5",
3131
"glob": "11.0.0",
3232
"grant": "5.4.23",

packages/server/src/features/buddy-project/cron-jobs/matching-cron.ts

+2
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,8 @@ export class MatchingCron {
7272

7373
private static async explainUnfortunateCircumstances(firstMessage: Message) {
7474
await firstMessage.delete();
75+
if (!firstMessage.channel.isSendable()) return;
76+
7577
await firstMessage.channel.send(
7678
'Right, this one is going to be disappointing... I had already matched you ' +
7779
'but your match had their DMs disabled, so I had to rollback everything.\n\n' +

packages/web/Dockerfile

+2-6
Original file line numberDiff line numberDiff line change
@@ -4,12 +4,9 @@ RUN apk add --no-cache libc6-compat && \
44

55
# Install dependencies only when needed
66
FROM base AS deps
7-
# Check https://github.com/nodejs/docker-node/tree/b4117f9333da4138b03a546ec926ef50a31506c3#nodealpine to understand why libc6-compat might be needed.
8-
RUN apk add --no-cache libc6-compat
97
WORKDIR /app
108

119
# Copy yarn data
12-
COPY .yarn/ ./.yarn/
1310
COPY .yarnrc.yml ./
1411
COPY yarn.lock package.json ./
1512

@@ -31,8 +28,7 @@ COPY --from=deps /app/packages/web/ ./packages/web/
3128
COPY --from=deps /app/node_modules/ ./node_modules/
3229

3330
# Copy dependency information and source, then build
34-
COPY yarn.lock .
35-
COPY package.json .
31+
COPY package.json yarn.lock .yarnrc.yml ./
3632
COPY packages/web/ ./packages/web
3733
WORKDIR /app/packages/web
3834

@@ -52,7 +48,7 @@ COPY --from=builder /app/packages/web/public/ ./packages/web/public/
5248
COPY --from=builder /app/packages/web/build/ ./packages/web/build/
5349
COPY --from=builder /app/packages/web/package.json ./packages/web/
5450

55-
COPY yarn.lock package.json ./
51+
COPY yarn.lock .yarnrc.yml package.json ./
5652

5753
EXPOSE 3000
5854

packages/web/next-env.d.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@
22
/// <reference types="next/image-types/global" />
33

44
// NOTE: This file should not be edited
5-
// see https://nextjs.org/docs/basic-features/typescript for more information.
5+
// see https://nextjs.org/docs/app/building-your-application/configuring/typescript for more information.

packages/web/package.json

+13-14
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,8 @@
3232
"@graphql-codegen/near-operation-file-preset": "3.0.0",
3333
"@graphql-codegen/typescript-graphql-request": "^6.2.0",
3434
"@graphql-codegen/typescript-operations": "^4.2.3",
35-
"@next/bundle-analyzer": "^15.0.0-canary.104",
36-
"@next/eslint-plugin-next": "^15.0.0-canary.104",
35+
"@next/bundle-analyzer": "^15.0.0-canary.173",
36+
"@next/eslint-plugin-next": "^15.0.0-canary.173",
3737
"@parcel/watcher": "^2.4.1",
3838
"@storybook/addon-essentials": "^8.3.3",
3939
"@storybook/addon-interactions": "^8.3.3",
@@ -45,15 +45,15 @@
4545
"@types/cookie": "0.6.0",
4646
"@types/eslint": "^8.56.12",
4747
"@types/node-cron": "^3.0.11",
48-
"@types/pg": "^8.11.10",
48+
"@types/pg": "8.10.2",
4949
"@types/prettier": "^3.0.0",
5050
"autoprefixer": "^10.4.20",
5151
"chromatic": "^11.10.4",
5252
"concurrently": "^8.2.2",
5353
"cross-env": "^7.0.3",
5454
"env-cmd": "^10.1.0",
5555
"eslint": "^8.57.1",
56-
"eslint-config-next": "^15.0.0-canary.104",
56+
"eslint-config-next": "^15.0.0-canary.173",
5757
"eslint-plugin-storybook": "^0.9.0",
5858
"postcss": "^8.4.47",
5959
"prettier": "^3.3.3",
@@ -67,26 +67,25 @@
6767
"@ebay/nice-modal-react": "^1.2.13",
6868
"@heroicons/react": "^2.1.5",
6969
"@icons-pack/react-simple-icons": "^10.0.0",
70-
"@payloadcms/db-postgres": "3.0.0-beta.109",
71-
"@payloadcms/next": "3.0.0-beta.109",
72-
"@payloadcms/richtext-slate": "3.0.0-beta.109",
73-
"@payloadcms/ui": "3.0.0-beta.109",
70+
"@payloadcms/db-postgres": "3.0.0-beta.111",
71+
"@payloadcms/next": "3.0.0-beta.111",
72+
"@payloadcms/richtext-slate": "3.0.0-beta.111",
73+
"@payloadcms/ui": "3.0.0-beta.111",
7474
"@radix-ui/react-dialog": "^1.1.1",
7575
"@radix-ui/react-dropdown-menu": "^2.1.1",
7676
"cookie": "0.6.0",
77-
"drizzle-orm": "0.32.1",
7877
"framer-motion": "^11.8.0",
7978
"graphql": "16.9.0",
8079
"graphql-request": "^7.1.0",
8180
"graphql-scalars": "1.23.0",
82-
"next": "15.0.0-canary.104",
81+
"next": "15.0.0-canary.173",
8382
"node-cron": "^3.0.3",
84-
"payload": "3.0.0-beta.109",
85-
"pg": "^8.13.0",
83+
"payload": "3.0.0-beta.111",
84+
"pg": "8.11.3",
8685
"pg-connection-string": "^2.7.0",
87-
"react": "^19.0.0-rc-06d0b89e-20240801",
86+
"react": "^19.0.0-rc-3edc000d-20240926",
8887
"react-animate-height": "^3.2.3",
89-
"react-dom": "^19.0.0-rc-06d0b89e-20240801",
88+
"react-dom": "^19.0.0-rc-3edc000d-20240926",
9089
"react-hook-form": "^7.53.0",
9190
"react-ssr-prepass": "1.5.0",
9291
"sharp": "0.33.5",

packages/web/src/app/(app)/layout.tsx

+3
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ import {Providers} from './providers';
1010

1111
import '../../../styles/globals.css';
1212

13+
// TODO see if we can get rid of this again in the future
14+
export const dynamic = 'force-dynamic';
15+
1316
const roboto = Roboto({
1417
weight: ['400', '900'],
1518
subsets: ['latin'],

packages/web/src/app/(payload)/admin/[[...segments]]/not-found.tsx

+4-4
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,12 @@ import config from '@payload-config';
33
import {importMap} from '../importMap';
44

55
type Args = {
6-
params: {
6+
params: Promise<{
77
segments: string[];
8-
};
9-
searchParams: {
8+
}>;
9+
searchParams: Promise<{
1010
[key: string]: string | string[];
11-
};
11+
}>;
1212
};
1313

1414
const NotFound = ({params, searchParams}: Args) =>

packages/web/src/app/(payload)/admin/[[...segments]]/page.tsx

+4-4
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,12 @@ import {importMap} from '../importMap';
66
/* DO NOT MODIFY IT BECAUSE IT COULD BE REWRITTEN AT ANY TIME. */
77

88
type Args = {
9-
params: {
9+
params: Promise<{
1010
segments: string[];
11-
};
12-
searchParams: {
11+
}>;
12+
searchParams: Promise<{
1313
[key: string]: string | string[];
14-
};
14+
}>;
1515
};
1616

1717
export const generateMetadata = ({

packages/web/src/app/(payload)/collections/groupchats.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ export const Groupchats: CollectionConfig = {
3737
type: 'text',
3838
required: true,
3939
validate: async (
40-
nameValue,
40+
nameValue: string | string[] | undefined | null,
4141
{
4242
data,
4343
req,
@@ -120,7 +120,7 @@ export const Groupchats: CollectionConfig = {
120120
],
121121
},
122122
validate: (
123-
url,
123+
url: string | string[] | undefined | null,
124124
{
125125
data,
126126
}: ValidateOptions<

0 commit comments

Comments
 (0)