diff --git a/README.md b/README.md index 4d12a82..eb53852 100644 --- a/README.md +++ b/README.md @@ -175,7 +175,7 @@ use log::Level; struct CustomLog {} impl LogAppender for CustomLog { - fn do_logs(&self, records: &[FastLogRecord]) { + fn do_logs(&mut self, records: &[FastLogRecord]) { for record in records { let now = DateTime::from(record.now); let data; diff --git a/example/src/custom_appender.rs b/example/src/custom_appender.rs index 7e19c1c..3065ee8 100644 --- a/example/src/custom_appender.rs +++ b/example/src/custom_appender.rs @@ -6,7 +6,7 @@ use log::Level; struct CustomLog {} impl LogAppender for CustomLog { - fn do_logs(&self, records: &[FastLogRecord]) { + fn do_logs(&mut self, records: &[FastLogRecord]) { for record in records { let now = DateTime::from(record.now); let data;