fix drinks
Took 4 minutes
This commit is contained in:
parent
4a20a9bc9e
commit
536de17d31
@ -239,7 +239,7 @@ export class iTender {
|
||||
for (let i of d.ingredients) {
|
||||
let c = await Container.findOne({content: i.type});
|
||||
|
||||
if (!c || c.content != i.type) {
|
||||
if (!c) {
|
||||
drinkAccept = false;
|
||||
break;
|
||||
}
|
||||
|
@ -65,9 +65,10 @@ function init(): Promise<void> {
|
||||
await iTender.checkNetwork();
|
||||
let drinkCount = await Drink.countDocuments({});
|
||||
if (iTender.internetConnection && iTender.status == iTenderStatus.READY && drinkCount < 3 ) {
|
||||
console.log("No drinks in the database. - Try to refresh from server...")
|
||||
await iTender.refreshFromServer();
|
||||
}
|
||||
}, 1000 * 20 ) ;
|
||||
}, 1000 * 15 ) ;
|
||||
|
||||
|
||||
// Containers
|
||||
|
Loading…
x
Reference in New Issue
Block a user