Skip to content

Commit c74451d

Browse files
authored
Merge 4fc90e4 into 5bdb9c7
2 parents 5bdb9c7 + 4fc90e4 commit c74451d

File tree

2 files changed

+259
-138
lines changed

2 files changed

+259
-138
lines changed

src/server/templates/typescript.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -681,8 +681,10 @@ export type Database = {
681681
{} as Record<string, typeof schemaFunctions>
682682
)
683683
for (const fnName in schemaFunctionsGroupedByName) {
684-
schemaFunctionsGroupedByName[fnName].sort((a, b) =>
685-
b.fn.definition.localeCompare(a.fn.definition)
684+
schemaFunctionsGroupedByName[fnName].sort(
685+
(a, b) =>
686+
a.fn.argument_types.localeCompare(b.fn.argument_types) ||
687+
a.fn.return_type.localeCompare(b.fn.return_type)
686688
)
687689
}
688690

0 commit comments

Comments
 (0)