Skip to content

Commit

Permalink
test
Browse files Browse the repository at this point in the history
  • Loading branch information
Hellol77 committed Oct 1, 2024
1 parent 78c40a9 commit e732a5d
Show file tree
Hide file tree
Showing 5 changed files with 3 additions and 9 deletions.
2 changes: 1 addition & 1 deletion backend/src/configs/typeorm.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ export class typeORMConfig implements TypeOrmOptionsFactory {
database: process.env.TYPEORM_DATABASE,
timezone: '+09:00',
entities: [__dirname + '/../**/*.entity.{js,ts}'],
synchronize: true,
synchronize: false,
};
}
}
1 change: 1 addition & 0 deletions backend/src/item/item.controller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ export class ItemController {
): Promise<CommentDto[]> {
const token = req.cookies['accessToken']; // 쿠키에서 accessToken 읽기
let userId: string | null = null;

if (token) {
try {
const decoded = this.jwtService.verify(token, {
Expand Down
1 change: 0 additions & 1 deletion backend/src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ async function bootstrap() {
const port = process.env.PORT || 80;
const app = await NestFactory.create(AppModule);
app.enableCors({
origin: true,
methods: 'GET,HEAD,PUT,PATCH,POST,DELETE,OPTIONS',
credentials: true,
});
Expand Down
1 change: 1 addition & 0 deletions frontend/src/components/comments/comment/Comment.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ export default function Comment(props) {
const { mutate: bestCommentLikeMutate } = useBestCommentLike(props.commentId, props.itemId);
const { mutate: commentLikeMutate } = useCommentLike(props.commentId, props.itemId);
const { mutate: deleteCommentMutate } = useDeleteComment(props.commentId, props.itemId);

const handleClick = () => {
if (props.isBest) {
bestCommentLikeMutate({ isHeart: props.isHeart });
Expand Down
7 changes: 0 additions & 7 deletions frontend/src/pages/LoginPage/LoginPage.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -8,18 +8,11 @@ export default function LoginPage() {
}&redirect_uri=${import.meta.env.VITE_KAKAO_REDIRECT_URI}`;
};

const handleCreateUser = () => {
fetch('http://localhost/user/create', {
method: 'POST',
credentials: 'include',
});
};
return (
<>
<S.LoginText>로그인 시 댓글 작성과 밸런스게임 제작이 가능합니다</S.LoginText>
<S.Kakaologin>
<S.KakaoImage src={KakaoImage} alt="kakao image" onClick={handleKakaoRedirect} />
<div onClick={handleCreateUser}></div>
</S.Kakaologin>
</>
);
Expand Down

0 comments on commit e732a5d

Please sign in to comment.