@@ -21,10 +21,9 @@ import Stubs, {
2121} from "./stubs.mjs" ;
2222import Settings , { SettingsKey } from "./settings.mjs" ;
2323import Logger from "./logger.mjs" ;
24- import { basename , dirname , extname , join } from "path" ;
24+ import { basename , extname , join } from "path" ;
2525import { PicoRemoteFileSystem } from "./filesystem.mjs" ;
2626import { Terminal } from "./terminal.mjs" ;
27- import { fileURLToPath } from "url" ;
2827import { ContextKeys } from "./models/contextKeys.mjs" ;
2928import DeviceWifiProvider from "./activitybar/deviceWifiTree.mjs" ;
3029import PackagesWebviewProvider from "./activitybar/packagesWebview.mjs" ;
@@ -100,7 +99,7 @@ export default class Activator {
10099 true
101100 ) ;
102101
103- this . stubs = new Stubs ( ) ;
102+ this . stubs = new Stubs ( context . extensionUri ) ;
104103 await this . stubs . update ( this . settings ) ;
105104
106105 const workspaceFolder = vscode . workspace . workspaceFolders ;
@@ -275,13 +274,10 @@ export default class Activator {
275274
276275 this . terminalOptions = {
277276 name : TERMINAL_NAME ,
278- iconPath : vscode . Uri . file (
279- join (
280- dirname ( fileURLToPath ( import . meta. url ) ) ,
281- ".." ,
282- "images" ,
283- "logo-256.png"
284- )
277+ iconPath : vscode . Uri . joinPath (
278+ context . extensionUri ,
279+ "images" ,
280+ "logo-256.png"
285281 ) ,
286282 isTransient : true ,
287283 pty : this . terminal ,
@@ -1246,7 +1242,7 @@ export default class Activator {
12461242 enableScripts : false ,
12471243 // Only allow the webview to access resources in our extension's media directory
12481244 localResourceRoots : [
1249- vscode . Uri . file ( join ( context . extensionPath , "images" ) ) ,
1245+ vscode . Uri . joinPath ( context . extensionUri , "images" ) ,
12501246 ] ,
12511247 }
12521248 ) ;
0 commit comments