The-Huginn / party-game

2 stars 1 forks source link

Investigate empty task #47

Closed The-Huginn closed 1 year ago

The-Huginn commented 1 year ago

Currently, we work around the problem of not resolvable tasks. However, this probably results in sending one empty task to the frontend. This might be some combination of type and repeat of a task

The-Huginn commented 1 year ago

It was observed on a task with price = 2 and type ALL from the following categories Miscellaneous

The-Huginn commented 1 year ago

The empty content was solved, however, we can probably still encounter a problem with empty body sent to the frontend.

The-Huginn commented 1 year ago

For example the following tasks required a secondary call to the backend. I suspect the gameTask column was set to null in ResolvedTask

{ "payload": { "repeat": "ALWAYS", "type": "DUO", "frequency": 2, "task": { "locale": "en", "content": "Change your places with each other" } }, "translations": [ { "locale": "sk", "translation": "Vymeňte si vzájomne miesta" } ] }

{ "payload": { "repeat": "ALWAYS", "task": { "locale": "en", "content": "Do a head stand" }, "price": { "enabled": "true", "price": 2 } }, "translations": [ { "locale": "sk", "translation": "Urob stojku" } ] },

{ "payload": { "repeat": "ALWAYS", "task": { "locale": "en", "content": "Close your eyes and others prepare you a drink, which you have to shot" }, "price": { "enabled": "true", "price": 2 } }, "translations": [ { "locale": "sk", "translation": "Zavri oči a ostatní ti pripravia miešaný drink, ktorý musíš vypiť" } ] },