From a06444c4df82d8fa609ac94fc32e00451b70fc6f Mon Sep 17 00:00:00 2001 From: u80864958 Date: Mon, 5 May 2025 09:00:15 +0200 Subject: [PATCH] fix context problems --- .vscode/launch.json | 17 +++++++++++++++++ backend/blog.db | Bin 36864 -> 36864 bytes backend/internal/auth/ctx.go | 2 +- backend/internal/auth/middleware.go | 1 + backend/internal/model/init.go | 16 ++++++++++------ .../post/create-post/create-post.component.ts | 6 ------ 6 files changed, 29 insertions(+), 13 deletions(-) create mode 100644 .vscode/launch.json diff --git a/.vscode/launch.json b/.vscode/launch.json new file mode 100644 index 0000000..091c1c3 --- /dev/null +++ b/.vscode/launch.json @@ -0,0 +1,17 @@ +{ + // Use IntelliSense to learn about possible attributes. + // Hover to view descriptions of existing attributes. + // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 + "version": "0.2.0", + "configurations": [ + + { + "name": "Launch Package", + "type": "go", + "request": "launch", + "mode": "auto", + "program": "${workspaceFolder}/backend/cmd/", + "args": ["serve"] + } + ] +} \ No newline at end of file diff --git a/backend/blog.db b/backend/blog.db index cef84496569cd1ab5e9e283b0a405372e31230f0..daf30104e4f3fbb5615486e6510cac1df870ca19 100644 GIT binary patch delta 446 zcmZozz|^pSX@WGP)I=F)MyZVnQ}r1+H-FRTbKqg&KEc5EiT4T5HSQCe1qF6+GdFRw zOuktYSRa+^YUpR=Y3T3nTjKBHl;s<2VBi<-m*o?ZZ4wz0SmKwJlHnVYUhZq;mJ#LR zmf@LMo*5O9QSO*bT2l5bq-m>wKy7Fy!sVO^M+lNOXy=xQA35?p0ro|;qQmlj!= z;+mD>pIDKdk?j#^WME{fYXCwD29{PP7FNcV+6G2e1_qn2)#x$vu<+ > Password: admin `, - }) + }) + } return db } diff --git a/frontend/src/app/routes/post/create-post/create-post.component.ts b/frontend/src/app/routes/post/create-post/create-post.component.ts index 5928d48..7c1163e 100644 --- a/frontend/src/app/routes/post/create-post/create-post.component.ts +++ b/frontend/src/app/routes/post/create-post/create-post.component.ts @@ -19,12 +19,6 @@ export class CreatePostComponent { content: '', }); - constructor() { - setTimeout(() => { - this.post.set({ ...this.post(), title: 'adf' }); - }, 1000); - } - publish() { this.postsService.createPost(this.post()); this.location.back();