@quenty/signal 3.2.0 → 4.0.0

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/CHANGELOG.md CHANGED
@@ -3,6 +3,14 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
5
5
 
6
+ # [4.0.0](https://github.com/Quenty/NevermoreEngine/compare/@quenty/signal@3.2.0...@quenty/signal@4.0.0) (2024-01-10)
7
+
8
+ **Note:** Version bump only for package @quenty/signal
9
+
10
+
11
+
12
+
13
+
6
14
  # [3.2.0](https://github.com/Quenty/NevermoreEngine/compare/@quenty/signal@3.1.0...@quenty/signal@3.2.0) (2024-01-08)
7
15
 
8
16
  **Note:** Version bump only for package @quenty/signal
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@quenty/signal",
3
- "version": "3.2.0",
3
+ "version": "4.0.0",
4
4
  "description": "A simple signal implementation for Roblox",
5
5
  "keywords": [
6
6
  "Roblox",
@@ -32,5 +32,5 @@
32
32
  "dependencies": {
33
33
  "@quenty/loader": "^7.3.0"
34
34
  },
35
- "gitHead": "075fb03a03f12ade8758f667767ba738204e0c4b"
35
+ "gitHead": "bf8135721716c976201cb82133e0186ea606b166"
36
36
  }
@@ -15,17 +15,7 @@ function SignalUtils.onNext(event, _function)
15
15
  assert(typeof(event) == "RBXScriptSignal", "Bad event")
16
16
  assert(type(_function) == "function", "Bad _function")
17
17
 
18
- local conn
19
- conn = event:Connect(function(...)
20
- if conn.Connected then
21
- return -- Multiple events got queued
22
- end
23
-
24
- conn:Disconnect()
25
- _function(...)
26
- end)
27
-
28
- return conn
18
+ return event:Once(_function)
29
19
  end
30
20
 
31
21
  return SignalUtils