Commit Graph

50 Commits

Author SHA1 Message Date
6227b64746 refactor: use GetValidatedDTO for user create validation 2026-01-10 23:00:08 +01:00
506e233347 test: adjust post creation tests for DTO validation 2026-01-10 22:59:56 +01:00
8c06c916e1 refactor: use GetValidatedDTO for request validation 2026-01-10 22:59:43 +01:00
29fcaab25d refactor: centralize DTO decode/validation and skip duplicate validation 2026-01-10 22:59:29 +01:00
422ff2473e test: align auth handler expectations with validation errors 2026-01-10 22:59:21 +01:00
dbe4879457 refactor: route validation errors through GetValidatedDTO 2026-01-10 22:59:13 +01:00
66b4b0e173 refactor: use AuthResponseDTO instead of services.AuthResult 2026-01-10 22:47:10 +01:00
f39dcff67d refactor: use DTOs instead of maps and nil for responses 2026-01-10 22:44:39 +01:00
a1466e860d refactor: remove redundant validation, trust middleware and service layer 2026-01-10 22:41:54 +01:00
a1e63b868f refactor: remove redundant validation and unused import 2026-01-10 22:41:43 +01:00
b6f5293c0f refactor: remove redundant validation 2026-01-10 22:41:31 +01:00
6643466d76 refactor: use ToSanitizedUserListDTO and ToPostListDTO helpers 2026-01-10 22:39:04 +01:00
9dcf748474 refactor: use ToPostListDTO and ToSearchPostListDTO helpers 2026-01-10 22:38:54 +01:00
cbfe0fd54c fix: use SanitizedUserListDTO instead of UserListDTO in GetUsers 2026-01-10 22:36:27 +01:00
ef4a05f8a5 refactor: use DTOs instead of manual maps in user responses 2026-01-10 22:34:43 +01:00
00ef0c236e refactor: use DTOs instead of manual maps in vote responses 2026-01-10 22:34:29 +01:00
2d58c15031 refactor: use DTOs instead of manual maps in post responses 2026-01-10 22:34:20 +01:00
523dac242e refactor: use DTOs instead of manual maps in auth responses 2026-01-10 22:34:07 +01:00
35ef42eb93 docs: document refresh token rotation and update examples 2026-01-08 06:28:48 +01:00
20f14d0863 refactor: use middleware.IsHTTPS instead of local function 2025-12-26 17:41:16 +01:00
d0914eb5dc test: update IsHTTPS test to use middleware.IsHTTPS 2025-12-26 17:41:04 +01:00
ab3efc99a8 refactor: remove duplicate IsHTTPS, use middleware.IsHTTPS 2025-12-26 17:40:47 +01:00
7b9250802e test: verify login works with legacy passwords 2025-12-26 17:36:13 +01:00
3f4cad5488 fix: remove password complexity validation from login 2025-12-26 17:35:59 +01:00
68716b977b fix: verify XSS sanitization in handler response instead of repository stub 2025-11-23 15:01:54 +01:00
dbe1600632 fix: indentation 2025-11-23 14:49:31 +01:00
d4595d8dbf fix: properly encoding the flash message in the redirect URL 2025-11-23 14:48:39 +01:00
db0369225e refactor: update references to VoteRequest 2025-11-23 14:26:45 +01:00
6e4b41894f fix: update test cases to use createCreatePostRequests 2025-11-23 14:22:35 +01:00
0a8ed2e27c fix: add explicite validation check for empty url, title and content length 2025-11-23 14:21:30 +01:00
216e8657f6 feat: add generic createRequestWithDTO along with helpers functions 2025-11-23 14:20:59 +01:00
fb7206c0a2 fix: test context handling 2025-11-23 14:20:09 +01:00
c25926514b fix: add explicit empty-field validation check in handlers 2025-11-23 14:19:54 +01:00
9c67cd2a47 feat: update vote handler to use dto VoteRequest and update MountRoutes 2025-11-23 13:47:31 +01:00
0e71b28615 feat: update CreateUser to use dto.RegisterRequest and update MountRoutes to apply validation middleware 2025-11-23 13:43:47 +01:00
cd740da57a feat: update methods to use validated DTOs and update MountRoutes 2025-11-23 13:43:14 +01:00
abe4a3dc88 feat: update handlers to use GetValidatedDTO instead of manual decoding and update MountRoutes to wrap handlers with WithValidation for all DTO-based routes 2025-11-23 13:42:52 +01:00
738243d945 feat: add ValidationMiddleware to RouteModuleConfig 2025-11-23 13:41:55 +01:00
4fbdfb6e4a feat: add two helpers function to retrieve validated DTOs from request context and to apply validation middleware 2025-11-23 13:41:07 +01:00
2d7ff9778b feat: update swagger comments following dtos relocation 2025-11-23 13:14:07 +01:00
4ff3fd3583 refactor: remove UpdatePostRequest definition and update swagger comments 2025-11-23 13:13:53 +01:00
73121cad15 refactor: remove all request DTO, update swagger comments and update token related methods to use dto ones 2025-11-23 13:13:23 +01:00
4b04461ebb style: minor formatting adjustments 2025-11-21 17:06:04 +01:00
5c239ad61d feat: add missing GetVoteCountsByPostID method to the errorVoteRepository test mock 2025-11-21 16:50:23 +01:00
ba17fa1b5a clean: remove now unused helpers 2025-11-14 06:50:14 +01:00
6426419b8b tests: add an unit test for APIHandler MountRoutes() 2025-11-11 04:26:33 +01:00
408b0000c8 feat: mount /api in API handler 2025-11-11 04:20:03 +01:00
78989eb9f8 fix: update route in swagger annotations 2025-11-10 21:44:33 +01:00
22d5773c7c fix: add missing swagger annotation for /api, /health and /metrics 2025-11-10 21:43:53 +01:00
71a031342b To gitea and beyond, let's go(-yco) 2025-11-10 19:12:09 +01:00