diff options
| author | TrainDoctor <traindoctor@protonmail.com> | 2022-10-30 10:38:49 -0700 |
|---|---|---|
| committer | TrainDoctor <traindoctor@protonmail.com> | 2022-10-30 10:38:49 -0700 |
| commit | d389b403b521c48920d872c6ddd133b63ada2528 (patch) | |
| tree | f05c55cb2f63da6c1dda35215123708a390291f2 /frontend | |
| parent | bace5143d28c42ffcc83509b7fcdf02b6cae6934 (diff) | |
| download | decky-loader-d389b403b521c48920d872c6ddd133b63ada2528.tar.gz decky-loader-d389b403b521c48920d872c6ddd133b63ada2528.zip | |
Disable store selection until PRs actually deploy to testing
Diffstat (limited to 'frontend')
| -rw-r--r-- | frontend/src/components/settings/pages/general/index.tsx | 4 | ||||
| -rw-r--r-- | frontend/src/store.tsx | 76 |
2 files changed, 43 insertions, 37 deletions
diff --git a/frontend/src/components/settings/pages/general/index.tsx b/frontend/src/components/settings/pages/general/index.tsx index d661b779..0ebfee12 100644 --- a/frontend/src/components/settings/pages/general/index.tsx +++ b/frontend/src/components/settings/pages/general/index.tsx @@ -5,7 +5,7 @@ import { FaShapes, FaTools } from 'react-icons/fa'; import { installFromURL } from '../../../../store'; import BranchSelect from './BranchSelect'; import RemoteDebuggingSettings from './RemoteDebugging'; -import StoreSelect from './StoreSelect'; +// import StoreSelect from './StoreSelect'; import UpdaterSettings from './Updater'; export default function GeneralSettings({ @@ -21,7 +21,7 @@ export default function GeneralSettings({ <div> <UpdaterSettings /> <BranchSelect /> - <StoreSelect /> + {/* <StoreSelect /> */} <RemoteDebuggingSettings /> <Field label="Developer mode" diff --git a/frontend/src/store.tsx b/frontend/src/store.tsx index 9b1c5d2e..3ef3e361 100644 --- a/frontend/src/store.tsx +++ b/frontend/src/store.tsx @@ -27,41 +27,47 @@ export type PluginUpdateMapping = Map<string, StorePluginVersion>; export async function getPluginList(): Promise<StorePlugin[]> { let version = await window.DeckyPluginLoader.updateVersion(); - let store = await getSetting<Store>('store', Store.Default); - let customURL = await getSetting<string>('store-url', 'https://plugins.deckbrew.xyz/plugins'); - let storeURL; - if (!store) { - console.log('Could not get a default store, using Default.'); - await setSetting('store-url', Store.Default); - return fetch('https://plugins.deckbrew.xyz/plugins', { - method: 'GET', - headers: { - 'X-Decky-Version': version.current, - }, - }).then((r) => r.json()); - } else { - switch (+store) { - case Store.Default: - storeURL = 'https://plugins.deckbrew.xyz/plugins'; - break; - case Store.Testing: - storeURL = 'https://testing.deckbrew.xyz/plugins'; - break; - case Store.Custom: - storeURL = customURL; - break; - default: - console.error('Somehow you ended up without a standard URL, using the default URL.'); - storeURL = 'https://plugins.deckbrew.xyz/plugins'; - break; - } - return fetch(storeURL, { - method: 'GET', - headers: { - 'X-Decky-Version': version.current, - }, - }).then((r) => r.json()); - } + return fetch('https://plugins.deckbrew.xyz/plugins', { + method: 'GET', + headers: { + 'X-Decky-Version': version.current, + }, + }).then((r) => r.json()); + // let store = await getSetting<Store>('store', Store.Default); + // let customURL = await getSetting<string>('store-url', 'https://plugins.deckbrew.xyz/plugins'); + // let storeURL; + // if (!store) { + // console.log('Could not get a default store, using Default.'); + // await setSetting('store-url', Store.Default); + // return fetch('https://plugins.deckbrew.xyz/plugins', { + // method: 'GET', + // headers: { + // 'X-Decky-Version': version.current, + // }, + // }).then((r) => r.json()); + // } else { + // switch (+store) { + // case Store.Default: + // storeURL = 'https://plugins.deckbrew.xyz/plugins'; + // break; + // case Store.Testing: + // storeURL = 'https://testing.deckbrew.xyz/plugins'; + // break; + // case Store.Custom: + // storeURL = customURL; + // break; + // default: + // console.error('Somehow you ended up without a standard URL, using the default URL.'); + // storeURL = 'https://plugins.deckbrew.xyz/plugins'; + // break; + // } + // return fetch(storeURL, { + // method: 'GET', + // headers: { + // 'X-Decky-Version': version.current, + // }, + // }).then((r) => r.json()); + // } } export async function installFromURL(url: string) { |
