Skip to content

Commit ef4e84e

Browse files
Merge branch 'main' into chore/891-eliminate-any-usage
2 parents 36b4279 + 28bf4f3 commit ef4e84e

32 files changed

Lines changed: 2622 additions & 197 deletions

.eslintrc.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,6 @@ module.exports = {
3636
'@typescript-eslint/no-namespace': 'off',
3737
// Allow @ts-nocheck / @ts-ignore where needed (tracked separately)
3838
'@typescript-eslint/ban-ts-comment': 'off',
39-
// Disallow console.log in production code
40-
'no-console': 'off',
39+
'no-console': 'error',
4140
},
4241
};

.github/workflows/ci.yml

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -94,14 +94,18 @@ jobs:
9494
DATABASE_URL: postgresql://postgres:postgres@localhost:5432/test
9595

9696
- name: Run tests
97-
run: npm test
97+
run: npm run test:all
9898
env:
9999
DATABASE_URL: postgresql://postgres:postgres@localhost:5432/test
100100
JWT_SECRET: test-secret-key
101101
JWT_REFRESH_SECRET: test-refresh-secret-key
102102

103-
- name: Check documents module test coverage (>70%)
104-
run: npx jest src/documents --coverage --collectCoverageFrom="src/documents/**/*.ts" --collectCoverageFrom="!src/documents/**/*.module.ts" --collectCoverageFrom="!src/documents/**/*.dto.ts" --coverageThreshold='{"global":{"statements":70,"branches":70,"functions":70,"lines":70}}'
103+
# Issue #913 – Enforce global (50%) and per-module coverage thresholds.
104+
# Thresholds are declared in jest.config.js so they are version-controlled
105+
# alongside the code they guard. The --passWithNoTests flag is set in
106+
# jest.config.js, so empty modules will not cause spurious failures.
107+
- name: Check coverage thresholds (jest.config.js)
108+
run: npm run test:cov
105109
env:
106110
DATABASE_URL: postgresql://postgres:postgres@localhost:5432/test
107111
JWT_SECRET: test-secret-key

CHANGELOG.md

Lines changed: 23 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/).
88
## [Unreleased]
99

1010
### Added
11+
1112
- Changelog documentation and maintenance guide
1213

1314
### Changed
@@ -25,6 +26,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/).
2526
## [1.0.0] - 2026-06-01
2627

2728
### Added
29+
2830
- **User Management**: Registration, authentication, and profile management with JWT tokens
2931
- **Role-Based Access Control**: USER, AGENT, and ADMIN roles with route protection
3032
- **Property Listings**: Create, manage, and search property listings
@@ -46,34 +48,36 @@ and this project adheres to [Semantic Versioning](https://semver.org/).
4648

4749
#### Database Migrations
4850

49-
| Feature | Migration |
50-
|---------|-----------|
51-
| Location & search logs | [`20260222084710_location`](prisma/migrations/20260222084710_location), [`20260222091519_add_search_logs`](prisma/migrations/20260222091519_add_search_logs) |
52-
| Password history | [`20260324073730_add_password_history`](prisma/migrations/20260324073730_add_password_history) |
53-
| API key rotation analytics | [`20260324084550_add_api_key_rotation_analytics`](prisma/migrations/20260324084550_add_api_key_rotation_analytics) |
54-
| Composite indexes | [`20260325120000_composite_indexes`](prisma/migrations/20260325120000_composite_indexes) |
55-
| SEO & soft delete | [`20260330000000_add_seo_and_soft_delete_fields`](prisma/migrations/20260330000000_add_seo_and_soft_delete_fields.sql) |
56-
| Auth security foundation | [`20260422000000_add_auth_security_foundation`](prisma/migrations/20260422000000_add_auth_security_foundation.sql) |
57-
| Google OAuth | [`20260422000001_add_google_oauth`](prisma/migrations/20260422000001_add_google_oauth) |
58-
| User preferences & verification docs | [`20260422000001_add_user_preferences_and_verification_documents`](prisma/migrations/20260422000001_add_user_preferences_and_verification_documents) |
59-
| Session management | [`20260422170000_add_session_management`](prisma/migrations/20260422170000_add_session_management.sql) |
60-
| Trust score | [`20260422180000_add_trust_score`](prisma/migrations/20260422180000_add_trust_score.sql) |
61-
| API key permissions & usage | [`20260423000000_add_api_key_permissions_and_usage`](prisma/migrations/20260423000000_add_api_key_permissions_and_usage.sql) |
62-
| Document features | [`20260424000000_add_document_features`](prisma/migrations/20260424000000_add_document_features.sql) |
63-
| Fraud detection | [`20260424010000_add_fraud_detection`](prisma/migrations/20260424010000_add_fraud_detection) |
64-
| Database backup management | [`20260425093000_add_database_backup_management`](prisma/migrations/20260425093000_add_database_backup_management) |
65-
| Email digest & transaction audit | [`20260429000000_add_email_digest`](prisma/migrations/20260429000000_add_email_digest), [`20260429000000_add_transaction_audit_log`](prisma/migrations/20260429000000_add_transaction_audit_log) |
66-
| Transaction lifecycle enforcement | [`20260429000000_enforce_transaction_status_lifecycle`](prisma/migrations/20260429000000_enforce_transaction_status_lifecycle) |
67-
| Transaction documents | [`20260429001000_add_transaction_documents`](prisma/migrations/20260429001000_add_transaction_documents) |
51+
| Feature | Migration |
52+
| ------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
53+
| Location & search logs | [`20260222084710_location`](prisma/migrations/20260222084710_location), [`20260222091519_add_search_logs`](prisma/migrations/20260222091519_add_search_logs) |
54+
| Password history | [`20260324073730_add_password_history`](prisma/migrations/20260324073730_add_password_history) |
55+
| API key rotation analytics | [`20260324084550_add_api_key_rotation_analytics`](prisma/migrations/20260324084550_add_api_key_rotation_analytics) |
56+
| Composite indexes | [`20260325120000_composite_indexes`](prisma/migrations/20260325120000_composite_indexes) |
57+
| SEO & soft delete | [`20260330000000_add_seo_and_soft_delete_fields`](prisma/migrations/20260330000000_add_seo_and_soft_delete_fields.sql) |
58+
| Auth security foundation | [`20260422000000_add_auth_security_foundation`](prisma/migrations/20260422000000_add_auth_security_foundation.sql) |
59+
| Google OAuth | [`20260422000001_add_google_oauth`](prisma/migrations/20260422000001_add_google_oauth) |
60+
| User preferences & verification docs | [`20260422000001_add_user_preferences_and_verification_documents`](prisma/migrations/20260422000001_add_user_preferences_and_verification_documents) |
61+
| Session management | [`20260422170000_add_session_management`](prisma/migrations/20260422170000_add_session_management.sql) |
62+
| Trust score | [`20260422180000_add_trust_score`](prisma/migrations/20260422180000_add_trust_score.sql) |
63+
| API key permissions & usage | [`20260423000000_add_api_key_permissions_and_usage`](prisma/migrations/20260423000000_add_api_key_permissions_and_usage.sql) |
64+
| Document features | [`20260424000000_add_document_features`](prisma/migrations/20260424000000_add_document_features.sql) |
65+
| Fraud detection | [`20260424010000_add_fraud_detection`](prisma/migrations/20260424010000_add_fraud_detection) |
66+
| Database backup management | [`20260425093000_add_database_backup_management`](prisma/migrations/20260425093000_add_database_backup_management) |
67+
| Email digest & transaction audit | [`20260429000000_add_email_digest`](prisma/migrations/20260429000000_add_email_digest), [`20260429000000_add_transaction_audit_log`](prisma/migrations/20260429000000_add_transaction_audit_log) |
68+
| Transaction lifecycle enforcement | [`20260429000000_enforce_transaction_status_lifecycle`](prisma/migrations/20260429000000_enforce_transaction_status_lifecycle) |
69+
| Transaction documents | [`20260429001000_add_transaction_documents`](prisma/migrations/20260429001000_add_transaction_documents) |
6870

6971
### Fixed
72+
7073
- Race condition in concurrent document uploads
7174
- Memory leak in WebSocket connection handling
7275
- Incorrect user role checks in disputes controller
7376
- SQL injection vulnerability in search queries
7477
- Email sending failures with retry logic
7578

7679
### Security
80+
7781
- Implemented password hashing with bcrypt
7882
- Added JWT token validation and expiration
7983
- Enforced HTTPS-only cookie transmission

0 commit comments

Comments
 (0)