From e6ddf6ea8422e6f262ae6e51324f73f6b64aeb81 Mon Sep 17 00:00:00 2001 From: Paulo Gustavo Veiga Date: Sun, 28 Feb 2021 08:09:40 -0800 Subject: [PATCH] bug: Fix starred rest issue on empty return --- packages/webapp/src/classes/client/rest-client/index.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packages/webapp/src/classes/client/rest-client/index.ts b/packages/webapp/src/classes/client/rest-client/index.ts index b70ad9fb..4c324fca 100644 --- a/packages/webapp/src/classes/client/rest-client/index.ts +++ b/packages/webapp/src/classes/client/rest-client/index.ts @@ -436,7 +436,7 @@ export default class RestClient implements Client { updateStarred(id: number, starred: boolean): Promise { const handler = (success: () => void, reject: (error: ErrorInfo) => void) => { axios - .put(`${this.baseUrl}/c/restful/maps/${id}/starred`, starred, { + .put(`${this.baseUrl}/c/restful/maps/${id}/starred`, Boolean(starred), { headers: { 'Content-Type': 'text/plain' }, }) .then(() => {