Unfavoritizing badge in profile responds with "FAILED"

Upon entering your profile on Developer Forum and attempting to unfavorite your badge, the badge responds with a message saying “FAILED” and keeps the badge on favorite.

I do not know the cause of this, but I believe it is worth reporting. I do not know when it started happening either but I assume it might have been after I picked the second badge as my favorite.

bug

2 Likes

I’ve had this bug for months, hadn’t said anything as I assumed it would be fixed but it hasn’t. Please fix Roblox :pray:
The api response is always 400 for me when I attempt to unfavorite

Strange that it doesn’t occur for me? Maybe try clearing cookie data on your browser or something.

Out of curiosity, have you tried applying a different badge as a fave? (It probably wouldn’t let you because you have 2/2 faved obviously, but I’m wondering if it would also say FAILED or throw a normal “you already have 2/2” error)

You can’t interact with the other badges.

It is very strange but clearing cookies does not help. I’ve tried multiple devices, incognito, doesn’t matter it always fails. Must be a backend issue.

You can’t click those, tho even when I bypass that I still get the same FAILED with error code 400 in console for the api response.

1 Like

Other thread:

1 Like

have been experiencing this for over a year now, still no fix

1 Like

I found a fix @pyxfluff @oliwieer4

const user_name = require("discourse/models/user").default.current().username;
const badges = await require("discourse/models/user-badge").default.findByUsername(user_name);
const favorites = new Map();
badges.filter((b)=>b.is_favorite).forEach((b)=>favorites.set(b.badge_id,b));
favorites.forEach((b)=>b.favorite());

Paste and run this in your browser’s console on the badges page and it will unfavorite all badges. The bug may happen again if you favorite a badge that you have multiple of

credit

1 Like