Commit 5dc29fd
Fix topics deleted via API not being deleted in org page (go-gitea#24825) (go-gitea#24829)
Backport go-gitea#24825 by @yardenshoham
The topics are saved in the repo_topic table with a repoID key. They are
also saved directly in the repository table.
Before this PR, only `AddTopic` and `SaveTopics` made sure the `topics`
field in the repository field was synced with the repo_topic table.
This PR makes sure `GenerateTopics` and `DeleteTopic` also sync the
`topics` in the repository table.
`RemoveTopicsFromRepo` doesn't need to sync the data as it is only used
to delete a repository.
- Fixes go-gitea#24820
(cherry picked from commit 04f9ab1)1 parent 88bde31 commit 5dc29fd
1 file changed
+25
-20
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
253 | 253 | | |
254 | 254 | | |
255 | 255 | | |
256 | | - | |
257 | | - | |
258 | | - | |
259 | | - | |
260 | | - | |
261 | | - | |
262 | | - | |
263 | | - | |
264 | | - | |
265 | | - | |
| 256 | + | |
266 | 257 | | |
267 | 258 | | |
268 | 259 | | |
| |||
281 | 272 | | |
282 | 273 | | |
283 | 274 | | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
284 | 280 | | |
285 | 281 | | |
286 | 282 | | |
| |||
347 | 343 | | |
348 | 344 | | |
349 | 345 | | |
350 | | - | |
351 | | - | |
352 | | - | |
353 | | - | |
354 | | - | |
355 | | - | |
356 | | - | |
357 | | - | |
358 | | - | |
359 | | - | |
| 346 | + | |
360 | 347 | | |
361 | 348 | | |
362 | 349 | | |
| |||
370 | 357 | | |
371 | 358 | | |
372 | 359 | | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
| 365 | + | |
| 366 | + | |
| 367 | + | |
| 368 | + | |
| 369 | + | |
| 370 | + | |
| 371 | + | |
| 372 | + | |
| 373 | + | |
| 374 | + | |
| 375 | + | |
| 376 | + | |
| 377 | + | |
373 | 378 | | |
374 | 379 | | |
0 commit comments