mirror of
https://github.com/Grasscutters/Cultivation.git
synced 2025-01-07 03:26:56 +08:00
Change to api.grasscutter.io
This commit is contained in:
parent
3b99b9137a
commit
b034c73c72
@ -186,9 +186,10 @@ async fn get_theme_list(data_dir: String) -> Vec<HashMap<String, String>> {
|
||||
}
|
||||
|
||||
#[tauri::command]
|
||||
// TODO: Replace with downloading the background file & saving it.
|
||||
async fn get_bg_file(bg_path: String, appdata: String) -> String {
|
||||
let copy_loc = appdata;
|
||||
let query = web::query("https://api.grasscutters.xyz/cultivation/query").await;
|
||||
let query = web::query("https://api.grasscutter.io/cultivation/query").await;
|
||||
let response_data: APIQuery = match serde_json::from_str(&query) {
|
||||
Ok(data) => data,
|
||||
Err(e) => {
|
||||
|
@ -75,7 +75,8 @@
|
||||
"active": true,
|
||||
"dialog": true,
|
||||
"endpoints": [
|
||||
"https://api.grasscutters.xyz/cultivation/update?version={{current_version}}"
|
||||
"https://api.grasscutter.io/cultivation/updater?version={{current_version}}",
|
||||
"https://api.grasscutters.xyz/cultivation/updater?version={{current_version}}"
|
||||
],
|
||||
"pubkey": "dW50cnVzdGVkIGNvbW1lbnQ6IG1pbmlzaWduIHB1YmxpYyBrZXk6IEIyM0MzMzk0NkM4OTQzNQpSV1ExbE1oR09jTWpDNFJ4NURsaS9mdHpDWmpBM3JNVHkrdER4bS9KdHFCQnNVSWs0ZjZTU295WAo="
|
||||
},
|
||||
|
@ -36,7 +36,7 @@ interface IState {
|
||||
bgFile: string;
|
||||
}
|
||||
|
||||
const DEFAULT_BG = 'https://api.grasscutters.xyz/content/bgfile'
|
||||
const DEFAULT_BG = 'https://api.grasscutter.io/cultivation/bgfile'
|
||||
|
||||
const downloadHandler = new DownloadHandler()
|
||||
|
||||
|
@ -42,7 +42,7 @@ export default class NewsSection extends React.Component<IProps, IState> {
|
||||
|
||||
async showLatestCommits() {
|
||||
if (!this.state.commitList) {
|
||||
const commits: string = await invoke('req_get', { url: 'https://api.grasscutters.xyz/cultivation/query' })
|
||||
const commits: string = await invoke('req_get', { url: 'https://api.grasscutter.io/cultivation/query' })
|
||||
let obj
|
||||
|
||||
try {
|
||||
|
Loading…
Reference in New Issue
Block a user