|
@@ -49,18 +49,18 @@ class SessionService {
|
|
|
return userData.data;
|
|
|
}
|
|
|
|
|
|
- getEventFromCookies(cookies: {
|
|
|
- userData: {
|
|
|
- username: string;
|
|
|
- userId: string;
|
|
|
- };
|
|
|
- }) {
|
|
|
- const userData = cookies.userData;
|
|
|
- if (!userData) {
|
|
|
- throw ApiError.UnauthorizedError();
|
|
|
- }
|
|
|
- return userData;
|
|
|
- }
|
|
|
+ // getEventFromCookies(cookies: {
|
|
|
+ // userData: {
|
|
|
+ // username: string;
|
|
|
+ // userId: string;
|
|
|
+ // };
|
|
|
+ // }) {
|
|
|
+ // const userData = cookies.userData;
|
|
|
+ // if (!userData) {
|
|
|
+ // throw ApiError.UnauthorizedError();
|
|
|
+ // }
|
|
|
+ // return userData;
|
|
|
+ // }
|
|
|
|
|
|
// TODO: Добавить ограничение в БД что только один ивент может быть актуальным
|
|
|
async getCurrentEventFromReq(req: Request) {
|