removed unused context

corrected comment
removed unused code-comment
This commit is contained in:
Ulf Gebhardt 2021-11-11 00:30:00 +01:00
parent e896759e1e
commit d7c5154912
Signed by: ulfgebhardt
GPG Key ID: DA6B843E748679C9

View File

@ -263,9 +263,9 @@ export class UserResolver {
@Authorized()
@Query(() => String)
async logout(@Ctx() context: any): Promise<boolean> {
async logout(): Promise<boolean> {
// TODO: We dont need this anymore, but might need this in the future in oder to invalidate a valid JWT-Token.
// Furthermore this hook can be useful for tracking user behaviour (did he logout or not? Flag him if he didn't on next login)
// Furthermore this hook can be useful for tracking user behaviour (did he logout or not? Warn him if he didn't on next login)
// The functionality is fully client side - the client just needs to delete his token with the current implementation.
// we could try to force this by sending `token: null` or `token: ''` with this call. But since it bares no real security
// we should just return true for now.
@ -574,7 +574,6 @@ export class UserResolver {
@Authorized()
@Query(() => Boolean)
async hasElopage(@Ctx() context: any): Promise<boolean> {
// const result = await apiGet(CONFIG.LOGIN_API_URL + 'hasElopage?session_id=' + context.sessionId)
const userRepository = getCustomRepository(UserRepository)
const userEntity = await userRepository.findByPubkeyHex(context.pubKey).catch()
if (!userEntity) {