mirror of
https://gitcode.com/gitea/gitea.git
synced 2025-05-20 16:48:28 +08:00
Delete old git.NewCommand() and use it as git.NewCommandContext() (#18552)
This commit is contained in:
@ -309,7 +309,7 @@ func runHookPostReceive(c *cli.Context) error {
|
||||
defer cancel()
|
||||
|
||||
// First of all run update-server-info no matter what
|
||||
if _, err := git.NewCommandContext(ctx, "update-server-info").Run(); err != nil {
|
||||
if _, err := git.NewCommand(ctx, "update-server-info").Run(); err != nil {
|
||||
return fmt.Errorf("Failed to call 'git update-server-info': %v", err)
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user