Cleanup map api endpoint
This commit is contained in:
parent
5c117dc216
commit
aa11262e3f
@ -11,13 +11,9 @@ export default async function handler(req, res) {
|
||||
const data = {
|
||||
// The maps data from the provided map hash
|
||||
bsr: mapData.id,
|
||||
songArt:
|
||||
"http://" +
|
||||
req.headers.host +
|
||||
"/api/beatsaver/art/" +
|
||||
mapHash +
|
||||
"?ext=" +
|
||||
mapData.versions[0].coverURL.split("/")[3].split(".")[1],
|
||||
songArt: `http://${req.headers.host}/api/beatsaver/art/${mapHash}?ext=${
|
||||
mapData.versions[0].coverURL.split("/")[3].split(".")[1]
|
||||
}`,
|
||||
};
|
||||
res.json({ error: false, data: data });
|
||||
}
|
||||
|
Reference in New Issue
Block a user