Add session stats to desktop app
This commit is contained in:
parent
857db0caf4
commit
93c53b4285
5 changed files with 17 additions and 3 deletions
|
|
@ -57,7 +57,7 @@ mod peer_info_reader;
|
|||
mod read_buf;
|
||||
mod session;
|
||||
mod session_persistence;
|
||||
mod session_stats;
|
||||
pub mod session_stats;
|
||||
mod spawn_utils;
|
||||
pub mod storage;
|
||||
mod stream_connect;
|
||||
|
|
|
|||
|
|
@ -1,5 +1,5 @@
|
|||
import { createContext } from "react";
|
||||
import { RqbitAPI } from "./api-types";
|
||||
import { RqbitAPI, SessionStats } from "./api-types";
|
||||
|
||||
export const APIContext = createContext<RqbitAPI>({
|
||||
listTorrents: () => {
|
||||
|
|
@ -38,5 +38,8 @@ export const APIContext = createContext<RqbitAPI>({
|
|||
getPlaylistUrl: function (index: number): string | null {
|
||||
throw new Error("Function not implemented.");
|
||||
},
|
||||
stats: function (): Promise<SessionStats> {
|
||||
throw new Error("Function not implemented.");
|
||||
},
|
||||
});
|
||||
export const RefreshTorrentStatsContext = createContext({ refresh: () => {} });
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue