Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
codekeyz committed Feb 16, 2024
1 parent 5e5f602 commit 0a12c2f
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ class TokenCreateCommand extends BaseGlobeCommand {

try {
final token = await api.createToken(
orgId: validated.organization.slug,
orgId: validated.organization.id,
name: name,
projectUuids: projects.map((e) => e.id).toList(),
expiresAt: expiry,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ class TokenDeleteCommand extends BaseGlobeCommand {

try {
await api.deleteToken(
orgId: validated.organization.slug,
orgId: validated.organization.id,
tokenId: tokenId,
);
deleteTokenProgress.complete('Token deleted');
Expand Down
4 changes: 2 additions & 2 deletions packages/globe_cli/lib/src/utils/api.dart
Original file line number Diff line number Diff line change
Expand Up @@ -634,14 +634,14 @@ class Token {
'name': final String name,
'organizationUuid': final String organizationUuid,
'expiresAt': final String expiresAt,
'cliTokenClaimProject': final List<dynamic> cliTokenClaimProject,
'projects': final List<dynamic> projects,
} =>
Token._(
uuid: uuid,
name: name,
organizationUuid: organizationUuid,
expiresAt: DateTime.parse(expiresAt),
cliTokenClaimProject: cliTokenClaimProject
cliTokenClaimProject: projects
.map((e) => (e as Map)['projectUuid'].toString())
.toList(),
),
Expand Down

0 comments on commit 0a12c2f

Please sign in to comment.