@@ -16,7 +16,7 @@ import { INITIAL_HIDE_MODELED_METHODS_VALUE } from "../shared/hide-modeled-metho
1616import { getModelingStatus } from "../shared/modeling-status" ;
1717import { assertNever } from "../../common/helpers-pure" ;
1818import type { ModeledMethod } from "../modeled-method" ;
19- import { groupMethods , sortGroupNames , sortMethods } from "../shared/sorting" ;
19+ import { groupMethods , sortGroupNames } from "../shared/sorting" ;
2020import type { Mode } from "../shared/mode" ;
2121import { INITIAL_MODE } from "../shared/mode" ;
2222import type { UrlValueResolvable } from "../../common/raw-result-types" ;
@@ -63,7 +63,6 @@ export class MethodsUsageDataProvider
6363 mode : Mode ,
6464 modeledMethods : Readonly < Record < string , readonly ModeledMethod [ ] > > ,
6565 modifiedMethodSignatures : ReadonlySet < string > ,
66- processedByAutoModelMethods : ReadonlySet < string > ,
6766 ) : Promise < void > {
6867 if (
6968 this . methods !== methods ||
@@ -74,15 +73,7 @@ export class MethodsUsageDataProvider
7473 this . modifiedMethodSignatures !== modifiedMethodSignatures
7574 ) {
7675 this . methods = methods ;
77- this . sortedTreeItems = createTreeItems (
78- sortMethodsInGroups (
79- methods ,
80- modeledMethods ,
81- mode ,
82- modifiedMethodSignatures ,
83- processedByAutoModelMethods ,
84- ) ,
85- ) ;
76+ this . sortedTreeItems = createTreeItems ( createGroups ( methods , mode ) ) ;
8677 this . databaseItem = databaseItem ;
8778 this . sourceLocationPrefix =
8879 await this . databaseItem . getSourceLocationPrefix ( this . cliServer ) ;
@@ -253,27 +244,9 @@ function urlValueResolvablesAreEqual(
253244 return false ;
254245}
255246
256- function sortMethodsInGroups (
257- methods : readonly Method [ ] ,
258- modeledMethods : Readonly < Record < string , readonly ModeledMethod [ ] > > ,
259- mode : Mode ,
260- modifiedMethodSignatures : ReadonlySet < string > ,
261- processedByAutoModelMethods : ReadonlySet < string > ,
262- ) : Method [ ] {
247+ function createGroups ( methods : readonly Method [ ] , mode : Mode ) : Method [ ] {
263248 const grouped = groupMethods ( methods , mode ) ;
264-
265- const sortedGroupNames = sortGroupNames ( grouped ) ;
266-
267- return sortedGroupNames . flatMap ( ( groupName ) => {
268- const group = grouped [ groupName ] ;
269-
270- return sortMethods (
271- group ,
272- modeledMethods ,
273- modifiedMethodSignatures ,
274- processedByAutoModelMethods ,
275- ) ;
276- } ) ;
249+ return sortGroupNames ( grouped ) . flatMap ( ( groupName ) => grouped [ groupName ] ) ;
277250}
278251
279252function createTreeItems ( methods : readonly Method [ ] ) : MethodTreeViewItem [ ] {
0 commit comments