#GQL Array input type

1 messages · Page 1 of 1 (latest)

atomic sigil
#

Hello,

i am overseeing something, can someone hint my why i get
"Error: Undefined type error. Make sure you are providing an explicit type for the "transactionByNzh" (parameter at index [0]) of the "TransactionResolvers" class."

Code:

  @Query(() => [transaction], { name: 'transactionByNzh' })
  async transactionByNzh(@Args('nzhId') nzhId: [number]): Promise<transaction[] | null> {
    return this.transactionService.transactionByNzh(nzhId);
  }
drifting tangle
#
@Args({ name: 'nzhId', type: () => [Number] })