Skip to content

Commit

Permalink
fix: fix composite query support in actor.ts (#739)
Browse files Browse the repository at this point in the history
* fix: fix composite query support in actor.ts

* changelog
  • Loading branch information
chenyan-dfinity authored Jul 14, 2023
1 parent 1b80eac commit d0001f6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions docs/generated/changelog.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ <h1>Agent-JS Changelog</h1>
<section>
<h2>Version x.x.x</h2>
<ul>
<li>fix: fix composite query in actor.ts</li>
<li>
fix: handle new update call errors (<a
href="https://github.com/dfinity/interface-spec/pull/143"
Expand Down
2 changes: 1 addition & 1 deletion packages/agent/src/actor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -367,7 +367,7 @@ function _createActorMethod(
blsVerify?: CreateCertificateOptions['blsVerify'],
): ActorMethod {
let caller: (options: CallConfig, ...args: unknown[]) => Promise<unknown>;
if (func.annotations.includes('query')) {
if (func.annotations.includes('query') || func.annotations.includes('composite_query')) {
caller = async (options, ...args) => {
// First, if there's a config transformation, call it.
options = {
Expand Down

0 comments on commit d0001f6

Please sign in to comment.