File tree Expand file tree Collapse file tree 1 file changed +14
-3
lines changed Expand file tree Collapse file tree 1 file changed +14
-3
lines changed Original file line number Diff line number Diff line change @@ -281,6 +281,19 @@ func Milestones(ctx *context.Context) {
281
281
}
282
282
}
283
283
284
+ showRepoIds := make (container.Set [int64 ], len (showRepos ))
285
+ for _ , repo := range showRepos {
286
+ if repo .ID > 0 {
287
+ showRepoIds .Add (repo .ID )
288
+ }
289
+ }
290
+ if len (repoIDs ) == 0 {
291
+ repoIDs = showRepoIds .Values ()
292
+ }
293
+ repoIDs = util .SliceRemoveAllFunc (repoIDs , func (v int64 ) bool {
294
+ return ! showRepoIds .Contains (v )
295
+ })
296
+
284
297
var pagerCount int
285
298
if isShowClosed {
286
299
ctx .Data ["State" ] = "closed"
@@ -298,9 +311,7 @@ func Milestones(ctx *context.Context) {
298
311
ctx .Data ["MilestoneStats" ] = milestoneStats
299
312
ctx .Data ["SortType" ] = sortType
300
313
ctx .Data ["Keyword" ] = keyword
301
- if milestoneStats .Total () != totalMilestoneStats .Total () {
302
- ctx .Data ["RepoIDs" ] = repoIDs
303
- }
314
+ ctx .Data ["RepoIDs" ] = repoIDs
304
315
ctx .Data ["IsShowClosed" ] = isShowClosed
305
316
306
317
pager := context .NewPagination (pagerCount , setting .UI .IssuePagingNum , page , 5 )
You can’t perform that action at this time.
0 commit comments