mirror of
https://github.com/Xevion/paperless-mobile.git
synced 2025-12-13 12:12:20 -06:00
fix: Enable logging in production
This commit is contained in:
19
lib/features/logging/models/formatted_log_message.dart
Normal file
19
lib/features/logging/models/formatted_log_message.dart
Normal file
@@ -0,0 +1,19 @@
|
||||
/// Class passed to the printer to be formatted and printed.
|
||||
class FormattedLogMessage {
|
||||
static const maxLength = 55;
|
||||
final String message;
|
||||
final String methodName;
|
||||
final String className;
|
||||
|
||||
FormattedLogMessage(
|
||||
this.message, {
|
||||
required this.methodName,
|
||||
required this.className,
|
||||
});
|
||||
|
||||
String format() {
|
||||
final formattedClassName = className.padLeft(25);
|
||||
final formattedMethodName = methodName.padRight(25);
|
||||
return '[$formattedClassName] - $formattedMethodName: $message';
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user