Skip to content

Commit

Permalink
Delete RepoTokenPeerInfo when del repo
Browse files Browse the repository at this point in the history
  • Loading branch information
杨赫然 committed Aug 19, 2024
1 parent 7387164 commit 72db471
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions server/repo-mgr.c
Original file line number Diff line number Diff line change
Expand Up @@ -611,8 +611,10 @@ seaf_repo_manager_del_repo (SeafRepoManager *mgr,
}

seaf_db_statement_query (mgr->seaf->db,
"DELETE FROM RepoUserToken WHERE repo_id = ?",
1, "string", repo_id);
"DELETE t.*, i.* FROM RepoUserToken t, "
"RepoTokenPeerInfo i WHERE t.token=i.token AND "
"t.repo_id=?",
1, "string", repo_id) < 0) {

seaf_db_statement_query (mgr->seaf->db,
"DELETE FROM RepoHistoryLimit WHERE repo_id = ?",
Expand Down

0 comments on commit 72db471

Please sign in to comment.