Skip to content

Commit

Permalink
fix instances of id still being a number
Browse files Browse the repository at this point in the history
  • Loading branch information
leowrites committed Oct 12, 2024
1 parent 838ffa0 commit 8cda885
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions memory-viz/src/memory_model.ts
Original file line number Diff line number Diff line change
Expand Up @@ -669,7 +669,7 @@ export class MemoryModel {
* @param {number} x - value for x coordinate of top left corner
* @param {number} y - value for y coordinate of top left corner
* @param {string} name - the name of the class
* @param {string} id - the hypothetical memory address number
* @param {number} id - the hypothetical memory address number
* @param {object} attributes - the attributes of the given class
* @param {boolean} stack_frame - set to true if you are drawing a stack frame
* @param {Style} style - object defining the desired style of the sequence. Must abide by the structure defined
Expand All @@ -681,7 +681,7 @@ export class MemoryModel {
x: number,
y: number,
name: string,
id: string,
id: number,
attributes: object,
stack_frame: boolean,
style: Style
Expand Down Expand Up @@ -763,7 +763,7 @@ export class MemoryModel {
"type"
);
} else {
this.drawProperties(parseInt(id), name, x, y, box_width, style);
this.drawProperties(id, name, x, y, box_width, style);
}

return SIZE;
Expand Down Expand Up @@ -912,7 +912,7 @@ export class MemoryModel {
obj.x,
obj.y,
obj.name,
String(obj.id),
obj.id,
obj.value,
is_frame,
obj.style
Expand All @@ -923,7 +923,7 @@ export class MemoryModel {
obj.x,
obj.y,
obj.type,
Number(obj.id),
obj.id,
obj.value,
obj.show_indexes,
obj.style
Expand Down

0 comments on commit 8cda885

Please sign in to comment.