Skip to content

Commit 7781f63

Browse files
committed
Use createNotEmittedStatement
1 parent cd59b6e commit 7781f63

File tree

3 files changed

+4
-21
lines changed

3 files changed

+4
-21
lines changed

common/api-review/database.api.md

Lines changed: 0 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -17,15 +17,8 @@ export function connectDatabaseEmulator(db: Database, host: string, port: number
1717

1818
// @public
1919
export class Database {
20-
;
2120
readonly app: FirebaseApp;
22-
;
23-
;
2421
readonly 'type' = "database";
25-
;
26-
;
27-
;
28-
;
2922
}
3023

3124
// @public
@@ -37,8 +30,6 @@ export interface DatabaseReference extends Query {
3730

3831
// @public
3932
export class DataSnapshot {
40-
;
41-
;
4233
child(path: string): DataSnapshot;
4334
exists(): boolean;
4435
exportVal(): any;
@@ -146,8 +137,6 @@ export function onChildRemoved(query: Query, callback: (snapshot: DataSnapshot)
146137

147138
// @public
148139
export class OnDisconnect {
149-
;
150-
;
151140
cancel(): Promise<void>;
152141
remove(): Promise<void>;
153142
set(value: unknown): Promise<void>;
@@ -188,11 +177,6 @@ export interface Query {
188177
readonly ref: DatabaseReference;
189178
toJSON(): string;
190179
toString(): string;
191-
;
192-
;
193-
;
194-
;
195-
;
196180
}
197181

198182
// @public
@@ -201,7 +185,6 @@ export function query(query: Query, ...queryConstraints: QueryConstraint[]): Que
201185
// @public
202186
export abstract class QueryConstraint {
203187
abstract readonly type: QueryConstraintType;
204-
;
205188
}
206189

207190
// @public

repo-scripts/prune-dts/prune-dts.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -483,7 +483,7 @@ function dropPrivateApiTransformer(
483483
if (
484484
!node.modifiers?.find(m => m.kind === ts.SyntaxKind.ExportKeyword)
485485
) {
486-
return factory.createEmptyStatement();
486+
return factory.createNotEmittedStatement(node);
487487
}
488488
}
489489

@@ -505,7 +505,7 @@ function dropPrivateApiTransformer(
505505
// Remove any class and interface members that are prefixed with
506506
// underscores.
507507
if (hasPrivatePrefix(node.name as ts.Identifier)) {
508-
return factory.createEmptyStatement();
508+
return factory.createNotEmittedStatement(node);
509509
}
510510
} else if (ts.isTypeReferenceNode(node)) {
511511
// For public types that refer internal types, find a public type that

scripts/build/create-overloads.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ function keepPublicFunctionsTransformer(
138138
return false;
139139
})
140140
) {
141-
return factory.createEmptyStatement();
141+
return factory.createNotEmittedStatement(node);
142142
}
143143

144144
const newParameters = node.parameters.map(param => {
@@ -190,7 +190,7 @@ function keepPublicFunctionsTransformer(
190190

191191
// remove all nodes other than the source file itself
192192
if (!ts.isSourceFile(node)) {
193-
return factory.createEmptyStatement();
193+
return factory.createNotEmittedStatement(node);
194194
}
195195

196196
return node;

0 commit comments

Comments
 (0)