@@ -127,7 +127,7 @@ export class GluaApiWriter {
127
127
let global = '' ;
128
128
129
129
if ( func . deprecated )
130
- global += `---@deprecated ${ func . deprecated ?? '' } \n` ;
130
+ global += `---@deprecated ${ removeNewlines ( func . deprecated ) } \n` ;
131
131
132
132
global += `${ func . parent } = {}\n\n` ;
133
133
@@ -179,7 +179,7 @@ export class GluaApiWriter {
179
179
const isContainedInTable = _enum . items [ 0 ] ?. key . includes ( '.' ) ?? false ;
180
180
181
181
if ( _enum . deprecated )
182
- api += `---@deprecated ${ _enum . deprecated ?? '' } \n` ;
182
+ api += `---@deprecated ${ removeNewlines ( _enum . deprecated ) } \n` ;
183
183
184
184
api += `---@enum ${ _enum . name } \n` ;
185
185
@@ -193,7 +193,7 @@ export class GluaApiWriter {
193
193
} else {
194
194
api += item . description ? `${ putCommentBeforeEachLine ( item . description , false ) } \n` : ''
195
195
if ( item . deprecated )
196
- api += `---@deprecated ${ item . deprecated ?? '' } \n` ;
196
+ api += `---@deprecated ${ removeNewlines ( item . deprecated ) } \n` ;
197
197
api += `${ key } = ${ item . value } \n` ;
198
198
}
199
199
} ;
@@ -224,7 +224,7 @@ export class GluaApiWriter {
224
224
225
225
for ( const field of struct . fields ) {
226
226
if ( field . deprecated )
227
- fields += `---@deprecated ${ field . deprecated ?? '' } \n` ;
227
+ fields += `---@deprecated ${ removeNewlines ( field . deprecated ) } \n` ;
228
228
229
229
fields += `---${ removeNewlines ( field . description ) . replace ( / \s + / g, ' ' ) } \n` ;
230
230
@@ -285,7 +285,7 @@ export class GluaApiWriter {
285
285
}
286
286
287
287
if ( func . deprecated )
288
- luaDocComment += `---@deprecated ${ func . deprecated ?? '' } \n` ;
288
+ luaDocComment += `---@deprecated ${ removeNewlines ( func . deprecated ) } \n` ;
289
289
290
290
return luaDocComment ;
291
291
}
0 commit comments