mirror of
https://github.com/Equicord/Equicord.git
synced 2025-06-18 02:47:03 -04:00
Notification API (#467)
Co-authored-by: Ven <vendicated@riseup.net> Co-authored-by: afn <hey@afn.lol> Co-authored-by: afn <afnzmn@gmail.com>
This commit is contained in:
parent
6114bc6b16
commit
1d995e58f5
25 changed files with 533 additions and 106 deletions
|
@ -50,7 +50,7 @@ export const filters = {
|
|||
}
|
||||
return true;
|
||||
},
|
||||
byDisplayName: (name: string): FilterFn => m =>
|
||||
byStoreName: (name: string): FilterFn => m =>
|
||||
m.constructor?.displayName === name
|
||||
};
|
||||
|
||||
|
@ -331,15 +331,15 @@ export function findByCodeLazy(...code: string[]) {
|
|||
/**
|
||||
* Find a store by its displayName
|
||||
*/
|
||||
export function findByDisplayName(name: string) {
|
||||
return find(filters.byDisplayName(name));
|
||||
export function findStore(name: string) {
|
||||
return find(filters.byStoreName(name));
|
||||
}
|
||||
|
||||
/**
|
||||
* findByDisplayName but lazy
|
||||
*/
|
||||
export function findByDisplayNameLazy(name: string) {
|
||||
return findLazy(filters.byDisplayName(name));
|
||||
export function findStoreLazy(name: string) {
|
||||
return findLazy(filters.byStoreName(name));
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue