refactor: Linting
This commit is contained in:
parent
2490e61a78
commit
437c7c62de
11 changed files with 219 additions and 187 deletions
|
@ -1,11 +1,11 @@
|
|||
import {ThemeController} from "@/controllers/themes.ts";
|
||||
import { ThemeController } from "@/controllers/themes.ts";
|
||||
|
||||
export function controllerGetter<T>(Factory: new () => T): () => T {
|
||||
export function controllerGetter<T>(factory: new () => T): () => T {
|
||||
let instance: T | undefined;
|
||||
|
||||
return (): T => {
|
||||
if (!instance) {
|
||||
instance = new Factory();
|
||||
instance = new factory();
|
||||
}
|
||||
return instance;
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue