refactor: useUserSettings uses global state to reduce db calls
This commit is contained in:
@@ -5,6 +5,10 @@ import { providerIcons } from '~/utils/model-mapping';
|
||||
const triplit = useTriplitClient();
|
||||
const { providers } = useModels();
|
||||
|
||||
const props = defineProps<{
|
||||
params?: string;
|
||||
}>();
|
||||
|
||||
if (providers.value === undefined) throw new Error('Providers not loaded');
|
||||
|
||||
// TODO: sometimes this code can create duplicate providers
|
||||
|
||||
Reference in New Issue
Block a user