We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 01eda1e commit ab09f36Copy full SHA for ab09f36
src/common/utils/pathUtils.ts
@@ -1,14 +1,15 @@
1
-import { Uri } from 'vscode';
+import { Uri, workspace } from 'vscode';
2
import { isWindows } from '../../managers/common/utils';
3
4
export function checkUri(scope?: Uri | Uri[] | string): Uri | Uri[] | string | undefined {
5
if (scope instanceof Uri) {
6
if (scope.scheme === 'vscode-notebook-cell') {
7
- return Uri.from({
8
- scheme: 'vscode-notebook',
9
- path: scope.path,
10
- authority: scope.authority,
+ workspace.notebookDocuments.find((doc) => {
+ if (doc.uri.toString() === scope.toString()) {
+ return doc;
+ }
11
});
12
+ return scope;
13
}
14
15
if (Array.isArray(scope)) {
0 commit comments