Skip to content

Commit 237d002

Browse files
committed
Fix an additional crash when switching files
1 parent 04c8f60 commit 237d002

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/main/java/org/itrace/ConnectionSingleton.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ else if(tokens[0].equals("gaze")) {
128128
line = logicalPosition.line + 1;
129129
column = logicalPosition.column + 1;
130130

131-
Document doc = FileEditorManager.getInstance(project).getSelectedTextEditor().getDocument();
131+
Document doc = editor.getDocument();
132132
String[] text_lines = doc.getText().split("\n");
133133
if (logicalPosition.line >= text_lines.length) {
134134
line = -1;

0 commit comments

Comments
 (0)