From dcd60228ed753a146bcb56bb5bf51166835acfb7 Mon Sep 17 00:00:00 2001 From: Dessalines Date: Sun, 19 Jan 2020 00:38:45 -0500 Subject: Strongly typing WebsocketJsonResponse. Forgot comment-form.tsx --- ui/src/components/navbar.tsx | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'ui/src/components/navbar.tsx') diff --git a/ui/src/components/navbar.tsx b/ui/src/components/navbar.tsx index 50bf19c7..fac54212 100644 --- a/ui/src/components/navbar.tsx +++ b/ui/src/components/navbar.tsx @@ -12,6 +12,7 @@ import { SortType, GetSiteResponse, Comment, + WebSocketJsonResponse, } from '../interfaces'; import { wsJsonToRes, @@ -181,7 +182,7 @@ export class Navbar extends Component { i.setState(i.state); } - parseMessage(msg: any) { + parseMessage(msg: WebSocketJsonResponse) { let res = wsJsonToRes(msg); if (res.error) { if (res.error == 'not_logged_in') { -- cgit v1.2.3