From a3955778e2f7329f2d649bf3af6010c5d8e09b67 Mon Sep 17 00:00:00 2001 From: Doonv <58695417+doonv@users.noreply.github.com> Date: Fri, 16 Aug 2024 18:05:44 +0300 Subject: [PATCH] fix doctest --- README.md | 12 ++++++------ src/lib.rs | 2 +- 2 files changed, 7 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 0343e7d..13596ec 100644 --- a/README.md +++ b/README.md @@ -42,16 +42,16 @@ 3. Add the plugins. ```rust,no_run - use bevy::{prelude::*,log::LogPlugin}; + use bevy::{prelude::*, log::LogPlugin}; use bevy_dev_console::prelude::*; App::new() .add_plugins(( - // Start capturing logs before the default plugins initiate. - ConsoleLogPlugin::default(), - // Add the default plugins without the LogPlugin. - // Not removing the LogPlugin will cause a panic! - DefaultPlugins.build().disable::(), + // Add the log plugin with the custom log layer + DefaultPlugins.set(LogPlugin { + custom_layer: custom_log_layer, + ..default() + }), // Add the dev console plugin itself. DevConsolePlugin, )) diff --git a/src/lib.rs b/src/lib.rs index 3435146..2190573 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -16,7 +16,7 @@ pub mod ui; /// Adds a Developer Console to your Bevy application. /// -/// Requires [ConsoleLogPlugin](logging::log_plugin::ConsoleLogPlugin). +/// Requires [custom_log_layer](logging::custom_log_layer). pub struct DevConsolePlugin; impl Plugin for DevConsolePlugin { fn build(&self, app: &mut App) {