File tree 2 files changed +10
-6
lines changed
2 files changed +10
-6
lines changed Original file line number Diff line number Diff line change @@ -436,9 +436,11 @@ func UpdateIssueProject(ctx *context.Context) {
436
436
437
437
projectID := ctx .FormInt64 ("id" )
438
438
for _ , issue := range issues {
439
- oldProjectID := issue .Project .ID
440
- if oldProjectID == projectID {
441
- continue
439
+ if issue .Project != nil {
440
+ oldProjectID := issue .Project .ID
441
+ if oldProjectID == projectID {
442
+ continue
443
+ }
442
444
}
443
445
444
446
if err := issues_model .ChangeProjectAssign (issue , ctx .Doer , projectID ); err != nil {
Original file line number Diff line number Diff line change @@ -385,9 +385,11 @@ func UpdateIssueProject(ctx *context.Context) {
385
385
386
386
projectID := ctx .FormInt64 ("id" )
387
387
for _ , issue := range issues {
388
- oldProjectID := issue .Project .ID
389
- if oldProjectID == projectID {
390
- continue
388
+ if issue .Project != nil {
389
+ oldProjectID := issue .Project .ID
390
+ if oldProjectID == projectID {
391
+ continue
392
+ }
391
393
}
392
394
393
395
if err := issues_model .ChangeProjectAssign (issue , ctx .Doer , projectID ); err != nil {
You can’t perform that action at this time.
0 commit comments