Added `"id"` field requirement to `"payload"` block.

This commit is contained in:
Tristan B. Kildaire 2020-05-13 23:00:24 +02:00
parent d5e3a86842
commit cc359a14f0
1 changed files with 5 additions and 0 deletions

View File

@ -160,6 +160,11 @@ public final class BesterConnection : Thread
/* Get the payload data */
JSONValue payloadData = payloadBlock["data"];
/* Get the payload tag */
string payloadTag = payloadBlock["id"].str();
/* Lookup the payloadType handler */
MessageHandler chosenHandler = server.findHandler(payloadType);