Skip to content

Clean up lemmy_db_schema expression module #5926

@dessalines

Description

@dessalines

To be less confusing, the new modules should be:

  • lemmy_db_schema::expressions (non-tuple expressions)
  • lemmy_db_schema::joins (things with .on)
  • lemmy_db_schema::selects (things that are meant to be the argument to .select)

The name "queries" is not accurate, so it should not be used.

Currently, there's some things in selects that don't belong there.

Also I think that doing this refactoring in the same PR as changes to views is too messy, so should be avoided in the future. It is however okay to add a new function in a new module, then do a separate PR that moves other things to that new module.

Originally posted by @dullbananas in #5924 (comment)

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions