refac: Signal.{notify,abort}를 동기함수로 변경
- async일 필요가 없음
This commit is contained in:
1 parent
e0784a670c
commit
d742633e6d
1 file changed
+2
-2
@@ -74,7 +74,7 @@ export class Signal<T = undefined> {
|
|||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
public async abort(): Promise<void> {
|
public abort(): void {
|
||||||
if(this.resolved){
|
if(this.resolved){
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
@@ -87,7 +87,7 @@ export class Signal<T = undefined> {
|
|||||||
this._resolve({type: 'abort'});
|
this._resolve({type: 'abort'});
|
||||||
}
|
}
|
||||||
|
|
||||||
public async notify(value?: T): Promise<void> {
|
public notify(value?: T): void {
|
||||||
if(this.resolved){
|
if(this.resolved){
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user