mirror of
https://github.com/discordjs/discord.js.git
synced 2026-03-09 16:13:31 +01:00
fix(docgen): fix up method return types
This commit is contained in:
@@ -26,7 +26,12 @@ export class DocumentedMethod extends DocumentedItem<Method> {
|
||||
async: this.data.async,
|
||||
generator: this.data.generator,
|
||||
returns: this.data.returns?.length
|
||||
? this.data.returns.map((p) => new DocumentedVarType(p, this.config).serialize())
|
||||
? this.data.returns.map((p) =>
|
||||
new DocumentedVarType(
|
||||
{ names: p.type.names, description: p.description, nullable: p.nullable },
|
||||
this.config,
|
||||
).serialize(),
|
||||
)
|
||||
: undefined,
|
||||
meta: new DocumentedItemMeta(this.data.meta, this.config).serialize(),
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user