Skip to content

Commit 6a0b154

Browse files
committed
cdp: dump runtime js only in debug mode
1 parent 7ce6998 commit 6a0b154

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/cdp/runtime.zig

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
// You should have received a copy of the GNU Affero General Public License
1717
// along with this program. If not, see <https://www.gnu.org/licenses/>.
1818

19+
const builtin = @import("builtin");
1920
const std = @import("std");
2021
const cdp = @import("cdp.zig");
2122

@@ -37,7 +38,7 @@ pub fn processMessage(cmd: anytype) !void {
3738

3839
fn sendInspector(cmd: anytype, action: anytype) !void {
3940
// save script in file at debug mode
40-
if (std.log.defaultLogEnabled(.debug)) {
41+
if (builtin.mode == .Debug) {
4142
try logInspector(cmd, action);
4243
}
4344

0 commit comments

Comments
 (0)