mirror of
https://github.com/Ale32bit/Capy64.git
synced 2025-01-18 10:36:44 +00:00
Add checks against fulfill nil values
This commit is contained in:
parent
4a9d2bad34
commit
44437e84f1
2 changed files with 5 additions and 0 deletions
|
@ -194,6 +194,7 @@ public class Event : IComponent
|
|||
|
||||
var task = TaskMeta.CheckTask(L, false);
|
||||
L.CheckAny(2);
|
||||
L.ArgumentCheck(!L.IsNil(2), 2, "value cannot be nil");
|
||||
|
||||
if(!task.UserTask)
|
||||
{
|
||||
|
|
|
@ -64,6 +64,10 @@ public class TaskMeta : IComponent
|
|||
|
||||
var container = tasks.NewThread();
|
||||
lk(container);
|
||||
if(container.IsNil(-1))
|
||||
{
|
||||
throw new Exception("Task result cannot be nil");
|
||||
}
|
||||
container.XMove(tasks, 1);
|
||||
tasks.Remove(-2);
|
||||
var emptySpot = FindSpot();
|
||||
|
|
Loading…
Reference in a new issue