diff options
author | Dessalines <tyhou13@gmx.com> | 2020-01-19 00:38:45 -0500 |
---|---|---|
committer | Dessalines <tyhou13@gmx.com> | 2020-01-19 00:38:45 -0500 |
commit | dcd60228ed753a146bcb56bb5bf51166835acfb7 (patch) | |
tree | f21c87ff98fd81af2d843fe1fe30c45b9e708af4 /ui/src/utils.ts | |
parent | a044718066623f19d51196d444bd199c1231cebe (diff) |
Strongly typing WebsocketJsonResponse. Forgot comment-form.tsx
Diffstat (limited to 'ui/src/utils.ts')
-rw-r--r-- | ui/src/utils.ts | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/ui/src/utils.ts b/ui/src/utils.ts index 363de663..90ef6899 100644 --- a/ui/src/utils.ts +++ b/ui/src/utils.ts @@ -16,6 +16,7 @@ import { ListingType, SearchType, WebSocketResponse, + WebSocketJsonResponse, } from './interfaces'; import { UserService } from './services/UserService'; import markdown_it from 'markdown-it'; @@ -39,7 +40,7 @@ export function randomStr() { .substr(2, 10); } -export function wsJsonToRes(msg: any): WebSocketResponse { +export function wsJsonToRes(msg: WebSocketJsonResponse): WebSocketResponse { let opStr: string = msg.op; return { op: UserOperation[opStr], |