Skip to content

Commit

Permalink
chore(nodejs): missing rename
Browse files Browse the repository at this point in the history
  • Loading branch information
MistEO committed Jan 16, 2025
1 parent 83aa31a commit 34ca862
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion source/binding/NodeJS/release/maa-node/src/maa.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -229,7 +229,7 @@ export declare function resource_status(handle: ResourceHandle, res_id: ResId):
export declare function resource_wait(handle: ResourceHandle, res_id: ResId): Promise<Status>
export declare function resource_loaded(handle: ResourceHandle): boolean
export declare function resource_get_hash(handle: ResourceHandle): string | null
export declare function resource_get_task_list(handle: ResourceHandle): string[] | null
export declare function resource_get_node_list(handle: ResourceHandle): string[] | null

// tasker.cpp

Expand Down
2 changes: 1 addition & 1 deletion source/binding/NodeJS/release/maa-node/src/resource.ts
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ export class ResourceBase {
}

get task_list() {
return maa.resource_get_task_list(this.handle)
return maa.resource_get_node_list(this.handle)
}
}

Expand Down
4 changes: 2 additions & 2 deletions source/binding/NodeJS/src/instance/resource.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ std::optional<std::string> resource_get_hash(Napi::External<ResourceInfo> info)
}
}

std::optional<std::vector<std::string>> resource_get_task_list(Napi::External<ResourceInfo> info)
std::optional<std::vector<std::string>> resource_get_node_list(Napi::External<ResourceInfo> info)
{
StringListBuffer buffer;
auto ret = MaaResourceGetNodeList(info.Data()->handle, buffer);
Expand Down Expand Up @@ -193,5 +193,5 @@ void load_instance_resource(Napi::Env env, Napi::Object& exports, Napi::External
BIND(resource_wait);
BIND(resource_loaded);
BIND(resource_get_hash);
BIND(resource_get_task_list);
BIND(resource_get_node_list);
}

0 comments on commit 34ca862

Please sign in to comment.