gitea/routers
wxiaoguang fb26b01688
Update object repo with the migrated repository (#18684) (#18726)
When migrating a repository (from GitHub) using the API (**POST** `repos/migrate`), the Code Indexer is not updated. Searching in the user interface will not return any results.

When migrating the same repository using **+/New Migration** in the web interface, the search index is updated and searching works as expected.

Caused by the fact that object `repo` is never updated with the migrated repo so `setting.Indexer.RepoIndexerEnabled && !repo.IsEmpty` in `modules/notification/indexer/indexer.go:NotifyMigrateRepository` always evaluates to `false`.

Tested with gitea:1.16.1, MariaDB:10, Breve in `Run Mode: Dev`.

Co-authored-by: Hugo Hoitink <10838836+hoitih@users.noreply.github.com>
2022-02-11 17:23:41 +01:00
..
api/v1 Update object repo with the migrated repository (#18684) (#18726) 2022-02-11 17:23:41 +01:00
common Instead of using routerCtx just escape the url before routing (#18086) 2021-12-25 00:50:49 +08:00
install Refactor HTTP request context (#17979) 2021-12-15 14:59:57 +08:00
private show pull link for agit pull request also (#18235) 2022-01-17 13:56:43 +08:00
utils A better go code formatter, and now make fmt can run in Windows (#17684) 2021-11-17 20:34:35 +08:00
web Ensure that blob-excerpt links work for wiki (#18587) (#18624) 2022-02-06 04:22:20 +00:00
init.go Move keys to models/asymkey (#17917) 2021-12-10 16:14:24 +08:00