diff options
author | Benjamin Simmonds <bsimmond@student.ethz.ch> | 2022-09-09 14:59:59 +0300 |
---|---|---|
committer | Benjamin Simmonds <bsimmond@student.ethz.ch> | 2022-09-09 14:59:59 +0300 |
commit | a9f9893925fe0eda9138f3addd803b0de2e4a632 (patch) | |
tree | fb1244eaf1ced40d145e5ee4be46d1167206bf0e | |
parent | 7cf801d90caf440f6080a8d1ee7bae8a95f9e28c (diff) |
Sort installed correctly when some don'r have timebenibenj/sortExtensionsByUpdateDate
-rw-r--r-- | src/vs/workbench/contrib/extensions/browser/extensionsViews.ts | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/vs/workbench/contrib/extensions/browser/extensionsViews.ts b/src/vs/workbench/contrib/extensions/browser/extensionsViews.ts index 7dcadaf6780..cacf2cf72cb 100644 --- a/src/vs/workbench/contrib/extensions/browser/extensionsViews.ts +++ b/src/vs/workbench/contrib/extensions/browser/extensionsViews.ts @@ -744,7 +744,9 @@ export class ExtensionsListView extends ViewPane { break; case SortBy.UpdateDate: extensions = extensions.sort((e1, e2) => - typeof e2.local?.installedTimestamp === 'number' && typeof e1.local?.installedTimestamp === 'number' ? e2.local.installedTimestamp - e1.local.installedTimestamp : NaN); + typeof e2.local?.installedTimestamp === 'number' && typeof e1.local?.installedTimestamp === 'number' ? e2.local.installedTimestamp - e1.local.installedTimestamp : + typeof e2.local?.installedTimestamp === 'number' ? 1 : + typeof e1.local?.installedTimestamp === 'number' ? -1 : NaN); break; case SortBy.AverageRating: case SortBy.WeightedRating: |