Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix issue with display time inside riverpod package #246

Merged
merged 2 commits into from
Jun 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions packages/talker_dio_logger/example/pubspec.lock
Original file line number Diff line number Diff line change
Expand Up @@ -287,7 +287,7 @@ packages:
sha256: "53fd8db9cec1d37b0574e12f07520d582019cb6c44abf5479a01505099a34a09"
url: "https://pub.dev"
source: hosted
version: "4.3.1"
version: "4.2.4"
share_plus:
dependency: transitive
description:
Expand Down Expand Up @@ -345,7 +345,7 @@ packages:
dependency: transitive
description:
name: talker
sha256: f876081a34027464e3f1ac785c7e470a5fca2515f4c8c277fb6f78a63e5cda1e
sha256: "9384aad65c72fecc4a37aeb95379716073e315e37e15cbb23a374cf3a828d60e"
url: "https://pub.dev"
source: hosted
version: "4.3.1"
Expand All @@ -367,7 +367,7 @@ packages:
dependency: transitive
description:
name: talker_logger
sha256: "8728b67e97a2cd484ed217ec9dca1e05063aa6c9464a1c095e77540f944b1c8a"
sha256: ed79a64aa1a0a71958258ea2f3d014f68ccdd8a41d436446e8603d90bc61c720
url: "https://pub.dev"
source: hosted
version: "4.3.1"
Expand Down
4 changes: 2 additions & 2 deletions packages/talker_flutter/example/pubspec.lock
Original file line number Diff line number Diff line change
Expand Up @@ -337,7 +337,7 @@ packages:
dependency: transitive
description:
name: talker
sha256: be2b3987fc64eb4eeb3c738cc89189eab49a36348c7b7bcf0e4fbf1473c913e9
sha256: "9384aad65c72fecc4a37aeb95379716073e315e37e15cbb23a374cf3a828d60e"
url: "https://pub.dev"
source: hosted
version: "4.3.1"
Expand All @@ -352,7 +352,7 @@ packages:
dependency: transitive
description:
name: talker_logger
sha256: "5837cf93cf2e37016c68da19536033ffc2af2ef0c12e33e926321fd20060d105"
sha256: ed79a64aa1a0a71958258ea2f3d014f68ccdd8a41d436446e8603d90bc61c720
url: "https://pub.dev"
source: hosted
version: "4.3.1"
Expand Down
24 changes: 12 additions & 12 deletions packages/talker_riverpod_logger/lib/riverpod_logs.dart
Original file line number Diff line number Diff line change
Expand Up @@ -37,12 +37,12 @@ class RiverpodAddLog extends TalkerLog {
@override
String generateTextMessage(
{TimeFormat timeFormat = TimeFormat.timeAndSeconds}) {
return _createMessage();
return _createMessage(timeFormat: timeFormat);
}

String _createMessage() {
String _createMessage({required TimeFormat timeFormat}) {
final sb = StringBuffer();
sb.write(displayTitleWithTime);
sb.write(displayTitleWithTime(timeFormat: timeFormat));
sb.write('\n$message');
sb.write(
'\n${'INITIAL state: ${settings.printStateFullData ? '\n$value' : value.runtimeType}'}');
Expand Down Expand Up @@ -79,12 +79,12 @@ class RiverpodUpdateLog extends TalkerLog {
String generateTextMessage({
TimeFormat timeFormat = TimeFormat.timeAndSeconds,
}) {
return _createMessage();
return _createMessage(timeFormat: timeFormat);
}

String _createMessage() {
String _createMessage({required TimeFormat timeFormat}) {
final sb = StringBuffer();
sb.write(displayTitleWithTime);
sb.write(displayTitleWithTime(timeFormat: timeFormat));
sb.write('\n$message');
sb.write(
'\n${'PREVIOUS state: ${settings.printStateFullData ? '\n$previousValue' : previousValue.runtimeType}'}');
Expand Down Expand Up @@ -116,12 +116,12 @@ class RiverpodDisposeLog extends TalkerLog {
String generateTextMessage({
TimeFormat timeFormat = TimeFormat.timeAndSeconds,
}) {
return _createMessage();
return _createMessage(timeFormat: timeFormat);
}

String _createMessage() {
String _createMessage({required TimeFormat timeFormat}) {
final sb = StringBuffer();
sb.write(displayTitleWithTime);
sb.write(displayTitleWithTime(timeFormat: timeFormat));
sb.write('\n$message');
return sb.toString();
}
Expand Down Expand Up @@ -156,12 +156,12 @@ class RiverpodFailLog extends TalkerLog {
String generateTextMessage({
TimeFormat timeFormat = TimeFormat.timeAndSeconds,
}) {
return _createMessage();
return _createMessage(timeFormat: timeFormat);
}

String _createMessage() {
String _createMessage({required TimeFormat timeFormat}) {
final sb = StringBuffer();
sb.write(displayTitleWithTime);
sb.write(displayTitleWithTime(timeFormat: timeFormat));
sb.write('\n$message');
sb.write('\n${'ERROR: \n$providerError'}');
sb.write('\n${'STACK TRACE: \n$providerStackTrace'}');
Expand Down
Loading