mirror of
				https://gitea.com/gitea/tea.git
				synced 2025-10-30 16:55:25 +01:00 
			
		
		
		
	Introduce workaround for missing pull head sha (#340)
fix #318 test with `tea pr 58` Co-authored-by: Norwin Roosen <git@nroo.de> Reviewed-on: https://gitea.com/gitea/tea/pulls/340 Reviewed-by: Norwin <noerw@noreply.gitea.io> Reviewed-by: Andrew Thornton <art27@cantab.net> Co-authored-by: 6543 <6543@obermui.de> Co-committed-by: 6543 <6543@obermui.de>
This commit is contained in:
		| @@ -12,6 +12,7 @@ import ( | ||||
| 	"code.gitea.io/tea/modules/interact" | ||||
| 	"code.gitea.io/tea/modules/print" | ||||
| 	"code.gitea.io/tea/modules/utils" | ||||
| 	"code.gitea.io/tea/modules/workaround" | ||||
|  | ||||
| 	"code.gitea.io/sdk/gitea" | ||||
| 	"github.com/urfave/cli/v2" | ||||
| @@ -65,6 +66,9 @@ func runPullDetail(cmd *cli.Context, index string) error { | ||||
| 	if err != nil { | ||||
| 		return err | ||||
| 	} | ||||
| 	if err := workaround.FixPullHeadSha(client, pr); err != nil { | ||||
| 		return err | ||||
| 	} | ||||
|  | ||||
| 	reviews, _, err := client.ListPullReviews(ctx.Owner, ctx.Repo, idx, gitea.ListPullReviewsOptions{}) | ||||
| 	if err != nil { | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 6543
					6543