From b9361f7afa7200cb000c73a2d9628ad3a9468c1e Mon Sep 17 00:00:00 2001 From: Gorniaky Date: Wed, 3 Jun 2026 14:27:24 -0300 Subject: [PATCH 1/2] fix: make locale option mandatory in UserLocaleCommand fix: update default duration locale to englishLocale --- lib/commands/user/locale.dart | 2 +- lib/extensions/duration.dart | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/commands/user/locale.dart b/lib/commands/user/locale.dart index 3d16688..a5735f7 100644 --- a/lib/commands/user/locale.dart +++ b/lib/commands/user/locale.dart @@ -6,7 +6,7 @@ import "package:discloud/utils/messages.dart"; final class UserLocaleCommand extends Command { UserLocaleCommand() { argParser - ..addOption("locale", abbr: "l", valueHelp: localeName) + ..addOption("locale", abbr: "l", mandatory: true, valueHelp: localeName) ..addFlag( "system", abbr: "s", diff --git a/lib/extensions/duration.dart b/lib/extensions/duration.dart index a4c9f6f..0e2cd81 100644 --- a/lib/extensions/duration.dart +++ b/lib/extensions/duration.dart @@ -8,7 +8,7 @@ extension DurationExtension on Duration { static final DurationLocale _durationLocale = .fromLanguageCode(Platform.localeName) ?? .fromLanguageCode(Intl.shortLocale(Platform.localeName)) ?? - const EnglishDurationLocale(); + englishLocale; String pretty({ bool abbreviated = true, From 84d40be0430feb8a7c9bf6ae8bc36d8029b32833 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Wed, 3 Jun 2026 17:28:43 +0000 Subject: [PATCH 2/2] docs: update b9361f7 --- docs/commands.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/commands.md b/docs/commands.md index 08c2f71..ab2b7b1 100644 --- a/docs/commands.md +++ b/docs/commands.md @@ -561,9 +561,9 @@ Usage: discloud user info [arguments] Set your locale Usage: discloud user locale [arguments] --h, --help Print this usage information. --l, --locale= --s, --system Use current system language (en_US) +-h, --help Print this usage information. +-l, --locale= (mandatory) +-s, --system Use current system language (en_US) ``` ### zip