Skip to content

Commit

Permalink
more refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
inoas committed May 6, 2024
1 parent 8103ada commit 84dbd7c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/cake/internal/query.gleam
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ fn select_builder_maybe_apply_join(
prepared_statement prp_stm: PreparedStatement,
query qry: SelectQuery,
) -> PreparedStatement {
prp_stm |> join_parts_apply_as_clause(qry.join)
prp_stm |> join_parts_apply_clause(qry.join)
}

fn select_builder_maybe_add_order_sql(query qry: SelectQuery) -> String {
Expand Down Expand Up @@ -759,7 +759,7 @@ pub fn select_part_from(s: String) -> SelectPart {
SelectString(s)
}

pub fn select_part_to_sql(part prt: SelectPart) {
fn select_part_to_sql(part prt: SelectPart) -> String {
case prt {
SelectString(string) -> string
SelectStringAlias(string, alias) -> string <> " AS " <> alias
Expand Down Expand Up @@ -969,7 +969,7 @@ pub fn where_part_apply_clause(
}
}

pub fn join_parts_apply_as_clause(
pub fn join_parts_apply_clause(
prepared_statement prp_stm: PreparedStatement,
parts prts: List(JoinPart),
) -> PreparedStatement {
Expand Down

0 comments on commit 84dbd7c

Please sign in to comment.