Skip to content

Commit

Permalink
ouais
Browse files Browse the repository at this point in the history
  • Loading branch information
sartek430 committed Oct 25, 2023
1 parent 7d23dbc commit a120654
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 7 deletions.
10 changes: 5 additions & 5 deletions backend/src/auth/auth.controller.ts
Original file line number Diff line number Diff line change
@@ -1,14 +1,14 @@
import { Body, Controller, Post, HttpCode, HttpStatus } from '@nestjs/common';
import { Body, Controller, Post, Logger } from '@nestjs/common';
import { AuthService } from './auth.service';
import { AuthLoginDto } from './dto/auth-login.dto';

@Controller('auth')
@Controller('login')
export class AuthController {
private readonly logger = new Logger(AuthController.name);
constructor(private authService: AuthService) {}

@HttpCode(HttpStatus.OK)
@Post('login')
signIn(@Body() authLoginDto: AuthLoginDto) {
@Post()
async login(@Body() authLoginDto: AuthLoginDto) {
return this.authService.login(authLoginDto);
}
}
2 changes: 1 addition & 1 deletion backend/src/users/users.controller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ import {
Query,
UseGuards,
} from '@nestjs/common';
import { JwtAuthGuard } from 'src/auth/jwt-auth.guard';
import { JwtAuthGuard } from '../auth/jwt-auth.guard';
import { IUserInfos, UserInfos } from 'src/decorators/user.decorators';
import { CreateUserDto } from './dto/create-user.dto';
import { UpdateUserDto } from './dto/update-user.dto';
Expand Down
2 changes: 2 additions & 0 deletions frontend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,8 @@
},
"scripts": {
"predeploy": "npm run build",
"lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0",
"preview": "vite preview",
"deploy": "gh-pages -d build",
"start": "vite",
"build": "vite build",
Expand Down
2 changes: 1 addition & 1 deletion frontend/src/App.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ function App() {
<Route path="/login" element={<Login />} /> {/* Login Page */}
<Route path="/signup" element={<Signup />} /> {/* Signup Page*/}
<Route path="*" element={<NotFound />} /> {/* Route 404 */}
<Route path="/freelanceHelper/dashboard" element={<Dashboard />} />
<Route path="/dashboard" element={<Dashboard />} />
{/* Dashboard Page */}
</Routes>
</Box>
Expand Down

0 comments on commit a120654

Please sign in to comment.