Browse Source
Feature/remove alias from user (#1218)
* Remove alias
* Update changelog
pull/1220/head
Thomas Kaul
2 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with
5 additions and
6 deletions
-
CHANGELOG.md
-
apps/api/src/app/auth/web-auth.service.ts
-
apps/api/src/app/user/user.service.ts
-
prisma/migrations/20220903065048_removed_alias_from_user/migration.sql
-
prisma/schema.prisma
-
prisma/seed.js
|
|
@ -10,6 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 |
|
|
|
### Changed |
|
|
|
|
|
|
|
- Decreased the rate limiter duration of queue jobs from 5 to 4 seconds |
|
|
|
- Removed the alias from the `User` database schema |
|
|
|
|
|
|
|
### Fixed |
|
|
|
|
|
|
|
|
|
@ -54,7 +54,7 @@ export class WebAuthService { |
|
|
|
rpName: 'Ghostfolio', |
|
|
|
rpID: this.rpID, |
|
|
|
userID: user.id, |
|
|
|
userName: user.alias, |
|
|
|
userName: '', |
|
|
|
timeout: 60000, |
|
|
|
attestationType: 'indirect', |
|
|
|
authenticatorSelection: { |
|
|
|
|
|
@ -43,7 +43,7 @@ export class UserService { |
|
|
|
include: { |
|
|
|
User: true |
|
|
|
}, |
|
|
|
orderBy: { User: { alias: 'asc' } }, |
|
|
|
orderBy: { alias: 'asc' }, |
|
|
|
where: { GranteeUser: { id } } |
|
|
|
}); |
|
|
|
let tags = await this.tagService.getByUser(id); |
|
|
@ -98,7 +98,6 @@ export class UserService { |
|
|
|
const { |
|
|
|
accessToken, |
|
|
|
Account, |
|
|
|
alias, |
|
|
|
authChallenge, |
|
|
|
createdAt, |
|
|
|
id, |
|
|
@ -116,7 +115,6 @@ export class UserService { |
|
|
|
const user: UserWithSettings = { |
|
|
|
accessToken, |
|
|
|
Account, |
|
|
|
alias, |
|
|
|
authChallenge, |
|
|
|
createdAt, |
|
|
|
id, |
|
|
|
|
|
@ -0,0 +1,2 @@ |
|
|
|
-- AlterTable |
|
|
|
ALTER TABLE "User" DROP COLUMN "alias"; |
|
|
@ -160,7 +160,6 @@ model Tag { |
|
|
|
|
|
|
|
model User { |
|
|
|
accessToken String? |
|
|
|
alias String? |
|
|
|
authChallenge String? |
|
|
|
createdAt DateTime @default(now()) |
|
|
|
id String @id @default(uuid()) |
|
|
|
|
|
@ -111,7 +111,6 @@ async function main() { |
|
|
|
} |
|
|
|
] |
|
|
|
}, |
|
|
|
alias: 'Demo', |
|
|
|
id: '9b112b4d-3b7d-4bad-9bdd-3b0f7b4dac2f', |
|
|
|
role: Role.DEMO |
|
|
|
}, |
|
|
|