fix: align BackendFinding type with backend Finding model (closes #50)#53
Conversation
…fwsrijan#50) The frontend BackendFinding type had flat file/line/tool fields, but the backend returns location.path, location.start_line, and metadata.engine. Updated the type definition and the mapper to extract values from the correct nested structure.
|
@onurege3467 Good work aligning the frontend type with the backend Finding model. Updating the mapper to read from A few things I'd like you to revisit:
Overall, the direction of the fix looks correct and addresses the root cause of the type mismatch. I just want to ensure we're not losing potentially useful data and that the frontend types accurately reflect the backend response shape. |
|
@Krishnx21 Thanks for the thorough review! Let me address each point:
Let me know if any of these need code changes or further discussion! |
|
@onurege3467 Sir for closing this PR. The issue wasn't assigned to you mate. |
Summary
The frontend BackendFinding type defined file, line, and tool as flat properties, but the backend Finding model returns these nested inside location.path, location.start_line, and metadata.engine.
Changes
frontend/src/app/lib/api.ts
frontend/src/app/lib/mappers.ts
Verification
Closes #50