Skip to content

Commit

Permalink
add number field to Rune response
Browse files Browse the repository at this point in the history
  • Loading branch information
brady.ouren committed Jul 23, 2024
1 parent ada15c7 commit cf16c32
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 0 deletions.
1 change: 1 addition & 0 deletions api/src/api/schemas.ts
Original file line number Diff line number Diff line change
Expand Up @@ -308,6 +308,7 @@ const RuneDetailResponseSchema = Type.Object({
rune: Type.Object(
{
id: RuneIdResponseSchema,
number: RuneNumberResponseSchema,
name: RuneNameResponseSchema,
spaced_name: RuneSpacedNameResponseSchema,
},
Expand Down
2 changes: 2 additions & 0 deletions api/src/api/util/helpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ export function parseActivityResponse(entry: DbItemWithRune<DbLedgerEntry>): Act
return {
rune: {
id: entry.rune_id,
number: entry.number,
name: entry.name,
spaced_name: entry.spaced_name,
},
Expand All @@ -91,6 +92,7 @@ export function parseBalanceResponse(item: DbItemWithRune<DbBalance>): BalanceRe
return {
rune: {
id: item.rune_id,
number: item.number,
name: item.name,
spaced_name: item.spaced_name,
},
Expand Down
1 change: 1 addition & 0 deletions api/src/pg/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ export type DbLedgerEntry = {

export type DbItemWithRune<T> = T & {
name: string;
number: number;
spaced_name: string;
divisibility: number;
total_operations: number;
Expand Down

0 comments on commit cf16c32

Please sign in to comment.