You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
refactor: create a uniform way of obtaining this extension's details.
Added:
- Added new `extensionDetails` private property in `Configuration` as a Map object.
- Added new `setExtensionData` method to set the data into the `extensionDetails` Map. Also added its method call into the `constructor`.
- Added new `getExtensionData` public method to get the value of a specified key from the `extensionDetails` Map.
Changed:
- Refactored `getExtensionNames` to be more generic.
This will be used in the new `setExtensionData` method to get and set the names, id and version into the `extensionDetails` Map.
- Changed the name to `getExtensionPackageJsonData`.
- Changed it's visibility to `private`.
- Changed the reading of the package.json file to use the `readJsonFile` method as it does the exact same thing, and makes it DRYer.
- Added the extension's version.
- Changed all references to the old `getExtensionNames` method to use the new `getExtensionData` method with the specific key needed.
Removed:
- Removed the unused `extensionNames` variable and method call from the `getExtensionsPathsFromWslEnv` method.
`Blade is set as disabled in the "${extensionNames.name}.disabledLanguages" setting. The "${extensionNames.name}.bladeOverrideComments" setting will have no affect.`,
1065
+
`Blade is set as disabled in the "${extensionName}.disabledLanguages" setting. The "${extensionName}.bladeOverrideComments" setting will have no affect.`,
1025
1066
"OK"
1026
1067
);
1027
1068
@@ -1036,8 +1077,6 @@ export class Configuration {
1036
1077
* @returns {Object} An object containing the user and built-in extensions paths.
1037
1078
*/
1038
1079
privategetExtensionsPathsFromWslEnv(){
1039
-
constextensionNames=this.getExtensionNames();
1040
-
1041
1080
/** Built-in Extensions */
1042
1081
1043
1082
// Get the path to the VS Code's exectutable from the VSCODE_CWD environment variable.
0 commit comments