Skip to content

## ❌ Upvoting PYQ Fails – branch field casting error #33

@Jatin917

Description

@Jatin917

🐛 Description:

When trying to upvote a PYQ, a 400 Bad Request error is returned from the backend. The response suggests a validation failure related to the branch field.


💥 Error (from network tab):

{
  "error": "Failed to upvote PYQ",
  "details": "pyqs validation failed: branch: Cast to ObjectId failed for value \"CSE\" (type string) at path \"branch\" because of \"BSONError\""
}

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions