Skip to content

Commit 02142ee

Browse files
authored
Merge pull request #71 from GeneralMagicio/rf6-easy-demo
Rf6 easy demo
2 parents 877e93b + e641a78 commit 02142ee

File tree

5 files changed

+26
-20
lines changed

5 files changed

+26
-20
lines changed

.gitignore

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,11 @@
55
/src/project-reading
66
# /src/rpgf5-data-import
77
/src/ai-summary
8+
/src/ai-summary-rf5
9+
/src/rf6-pw-ranking
10+
/src/rf6-data-import
11+
/git-ignored-archive
12+
813

914
# Envs
1015

src/auth/auth.controller.ts

Lines changed: 7 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -60,17 +60,14 @@ export class AuthController {
6060

6161
@ApiResponse({ status: 200, description: 'Sets an auth cookie' })
6262
@Post('/login')
63-
async login(
64-
@Res() res: Response,
65-
@Body() { message, signature, address }: LoginDTO,
66-
) {
63+
async login(@Res() res: Response, @Body() { address }: LoginDTO) {
6764
let isNewUser = false;
68-
const isAuthentic = await this.authService.verifyUser(
69-
message,
70-
signature as `0x${string}`,
71-
address as `0x${string}`,
72-
);
73-
if (!isAuthentic) throw new UnauthorizedException('Invalid signature');
65+
// const isAuthentic = await this.authService.verifyUser(
66+
// message,
67+
// signature as `0x${string}`,
68+
// address as `0x${string}`,
69+
// );
70+
// if (!isAuthentic) throw new UnauthorizedException('Invalid signature');
7471

7572
let user = await this.prismaService.user.findFirst({
7673
where: { address },

src/auth/auth.service.ts

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -147,11 +147,12 @@ export class AuthService {
147147
) => {
148148
try {
149149
// await this.isNonceValid(message.nonce);
150-
const valid = await verifyMessage({
151-
address,
152-
message,
153-
signature,
154-
});
150+
// const valid = await verifyMessage({
151+
// address,
152+
// message,
153+
// signature,
154+
// });
155+
const valid = true;
155156
return valid;
156157
} catch (err) {
157158
return false;

src/auth/dto/login.dto.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -77,11 +77,11 @@ export class SiweMessageClass {
7777
}
7878

7979
export class LoginDTO {
80-
@ApiProperty()
81-
message: string;
80+
// @ApiProperty()
81+
// message: string;
8282

83-
@ApiProperty()
84-
signature: string;
83+
// @ApiProperty()
84+
// signature: string;
8585

8686
@ApiProperty()
8787
address: string;

tsconfig.json

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,5 +15,8 @@
1515
"incremental": true,
1616
"skipLibCheck": true,
1717
"noFallthroughCasesInSwitch": false
18-
}
18+
},
19+
"include": [
20+
"src/**/*"
21+
]
1922
}

0 commit comments

Comments
 (0)