@rbxts/covenant 2.0.0 → 2.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rbxts/covenant",
3
- "version": "2.0.0",
3
+ "version": "2.0.1",
4
4
  "main": "src/init.luau",
5
5
  "scripts": {
6
6
  "build": "rbxtsc",
package/src/covenant.d.ts CHANGED
@@ -68,7 +68,7 @@ export declare class Covenant {
68
68
  recipe: (entities: ReadonlyMap<T, Entity>, updateId: number, hooks: CovenantHooks) => {
69
69
  statesToCreate?: T[];
70
70
  statesToDelete?: T[];
71
- };
71
+ } | undefined;
72
72
  }): void;
73
73
  private worldEntity;
74
74
  worldQuery<T extends Id[]>(...components: T): import("@rbxts/jecs").Query<import("@rbxts/jecs").InferComponents<T>>;
package/src/covenant.luau CHANGED
@@ -672,7 +672,11 @@ do
672
672
  local updater = function()
673
673
  lastUpdateId += 1
674
674
  local updateId = lastUpdateId
675
- local _binding = recipe(entities, updateId, hooks)
675
+ local modifiers = recipe(entities, updateId, hooks)
676
+ if modifiers == nil then
677
+ return nil
678
+ end
679
+ local _binding = modifiers
676
680
  local statesToCreate = _binding.statesToCreate
677
681
  local statesToDelete = _binding.statesToDelete
678
682
  local _result = statesToCreate