fix: set project correctly on restart

This commit is contained in:
CJ van den Berg 2024-10-28 19:58:47 +01:00
parent bd62dfcdc1
commit d0de867d91
Signed by: neurocyte
GPG key ID: 8EB1E1BB660E3FB9
2 changed files with 5 additions and 1 deletions

View file

@ -363,6 +363,9 @@ const cmds = struct {
pub const open_config_meta = .{ .description = "Edit configuration file" };
pub fn restore_session(self: *Self, _: Ctx) Result {
if (tp.env.get().str("project").len == 0) {
try open_project_cwd(self, .{});
}
try self.create_editor();
try self.read_restore_info();
tui.need_render();