Sort extract constant above extract function (#35580)
This commit is contained in:
parent
a78342a160
commit
9a9baebdd6
|
@ -66,14 +66,6 @@ namespace ts.refactor.extractSymbol {
|
|||
|
||||
const infos: ApplicableRefactorInfo[] = [];
|
||||
|
||||
if (functionActions.length) {
|
||||
infos.push({
|
||||
name: refactorName,
|
||||
description: getLocaleSpecificMessage(Diagnostics.Extract_function),
|
||||
actions: functionActions
|
||||
});
|
||||
}
|
||||
|
||||
if (constantActions.length) {
|
||||
infos.push({
|
||||
name: refactorName,
|
||||
|
@ -82,6 +74,14 @@ namespace ts.refactor.extractSymbol {
|
|||
});
|
||||
}
|
||||
|
||||
if (functionActions.length) {
|
||||
infos.push({
|
||||
name: refactorName,
|
||||
description: getLocaleSpecificMessage(Diagnostics.Extract_function),
|
||||
actions: functionActions
|
||||
});
|
||||
}
|
||||
|
||||
return infos.length ? infos : emptyArray;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue