mirror of
https://github.com/619dev/PaperPhone.git
synced 2026-05-08 14:57:04 +08:00
7 lines
186 B
JavaScript
7 lines
186 B
JavaScript
export const normalizeProvider = (input) => {
|
|
if (typeof input === "function")
|
|
return input;
|
|
const promisified = Promise.resolve(input);
|
|
return () => promisified;
|
|
};
|