Change loader id on navigation

This appears to be what chrome is doing. I don't know why we weren't before.
This commit is contained in:
Karl Seguin
2025-09-02 21:05:22 +08:00
parent 2ac9b2088a
commit e237e709b6
2 changed files with 1 additions and 5 deletions

View File

@@ -103,7 +103,6 @@ pub fn CDPT(comptime TypeProvider: type) type {
pub fn handleMessage(self: *Self, msg: []const u8) bool {
// if there's an error, it's already been logged
self.processMessage(msg) catch return false;
// self.pageWait();
return true;
}

View File

@@ -164,10 +164,7 @@ pub fn pageNavigate(arena: Allocator, bc: anytype, event: *const Notification.Pa
var cdp = bc.cdp;
if (event.opts.reason != .address_bar) {
bc.loader_id = bc.cdp.loader_id_gen.next();
}
const loader_id = bc.loader_id;
const target_id = bc.target_id orelse unreachable;
const session_id = bc.session_id orelse unreachable;