Skip to content

Commit

Permalink
[usage] Fix conversion of from and to pb.Timestamp
Browse files Browse the repository at this point in the history
  • Loading branch information
easyCZ authored and roboquat committed Jul 25, 2022
1 parent 6a1f754 commit 826a0bd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions components/server/ee/src/workspace/gitpod-server-impl.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2110,10 +2110,10 @@ export class GitpodServerEEImpl extends GitpodServerImpl {
await this.guardCostCenterAccess(ctx, user.id, attributionId, "get");

if (from) {
timestampFrom = new Timestamp().setSeconds(from);
timestampFrom = Timestamp.fromDate(new Date(from));
}
if (to) {
timestampTo = new Timestamp().setSeconds(to);
timestampTo = Timestamp.fromDate(new Date(to));
}
const usageClient = this.usageServiceClientProvider.getDefault();
const response = await usageClient.listBilledUsage(ctx, attributionId, timestampFrom, timestampTo);
Expand Down

0 comments on commit 826a0bd

Please sign in to comment.