fix: use 1 based offsets in get_mru_position
This commit is contained in:
		
							parent
							
								
									3e97f6627c
								
							
						
					
					
						commit
						cbe656fe44
					
				
					 1 changed files with 1 additions and 1 deletions
				
			
		| 
						 | 
					@ -129,7 +129,7 @@ pub fn get_mru_position(self: *Self, from: tp.pid_ref, file_path: []const u8) !v
 | 
				
			||||||
    for (self.files.items) |*file| {
 | 
					    for (self.files.items) |*file| {
 | 
				
			||||||
        if (!std.mem.eql(u8, file.path, file_path)) continue;
 | 
					        if (!std.mem.eql(u8, file.path, file_path)) continue;
 | 
				
			||||||
        if (file.row != 0)
 | 
					        if (file.row != 0)
 | 
				
			||||||
            try from.send(.{ "cmd", "goto", .{ file.row, file.col } });
 | 
					            try from.send(.{ "cmd", "goto", .{ file.row + 1, file.col + 1 } });
 | 
				
			||||||
        return;
 | 
					        return;
 | 
				
			||||||
    }
 | 
					    }
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue