Skip to content

Commit

Permalink
Fix typescript API return type
Browse files Browse the repository at this point in the history
  • Loading branch information
HuakunShen committed Sep 4, 2024
1 parent 2527770 commit c28dd60
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "tauri-plugin-system-info"
version = "2.0.5"
version = "2.0.6"
authors = ["Huakun"]
edition = "2021"
rust-version = "1.70"
Expand Down
6 changes: 3 additions & 3 deletions dist-js/api.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ export declare function name(): Promise<String>;
export declare function kernelVersion(): Promise<String>;
export declare function osVersion(): Promise<String>;
export declare function staticInfo(): Promise<StaticInfo>;
export declare function components(): Promise<Component>;
export declare function cpus(): Promise<Cpu>;
export declare function components(): Promise<Component[]>;
export declare function cpus(): Promise<Cpu[]>;
export declare function cpuCount(): Promise<number>;
export declare function cpuInfo(): Promise<CpuInfo>;
export declare function disks(): Promise<Disk[]>;
Expand All @@ -22,5 +22,5 @@ export declare function refreshMemory(): Promise<void>;
export declare function refreshCpu(): Promise<void>;
export declare function refreshProcesses(): Promise<void>;
export declare function debugCommand(): Promise<unknown>;
export declare function batteries(): Promise<Battery>;
export declare function batteries(): Promise<Battery[]>;
//# sourceMappingURL=api.d.ts.map
2 changes: 1 addition & 1 deletion dist-js/api.d.ts.map

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions guest-js/api.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,11 +48,11 @@ export function staticInfo(): Promise<StaticInfo> {
return invoke("plugin:system-info|static_info");
}
// Components
export function components(): Promise<Component> {
export function components(): Promise<Component[]> {
return invoke("plugin:system-info|components");
}
// Cpu
export function cpus(): Promise<Cpu> {
export function cpus(): Promise<Cpu[]> {
return invoke("plugin:system-info|cpus");
}
export function cpuCount(): Promise<number> {
Expand Down Expand Up @@ -91,6 +91,6 @@ export function debugCommand() {
return invoke("plugin:system-info|debug");
}

export function batteries(): Promise<Battery> {
export function batteries(): Promise<Battery[]> {
return invoke("plugin:system-info|batteries");
}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "tauri-plugin-system-info-api",
"version": "2.0.5",
"version": "2.0.6",
"author": "Huakun",
"description": "System Info Plugin for Tauri Apps",
"repository": {
Expand Down

0 comments on commit c28dd60

Please sign in to comment.