[server][delete] return list of apps being used

This commit is contained in:
Neeraj Gupta
2024-11-22 16:17:08 +05:30
parent 8e215d783f
commit 338c2ec369
3 changed files with 25 additions and 0 deletions

View File

@@ -49,9 +49,15 @@ func (c *UserController) GetDeleteChallengeToken(ctx *gin.Context) (*ente.Delete
if err != nil {
return nil, stacktrace.Propagate(err, "")
}
apps, err := c.UserAuthRepo.GetAppsForUser(userID)
if err != nil {
return nil, stacktrace.Propagate(err, "")
}
return &ente.DeleteChallengeResponse{
EncryptedChallenge: &encryptedToken,
AllowDelete: true,
Apps: apps,
}, nil
}