Skip to content

Fixed internal server error when sorting timelogs

What does this MR do and why?

Fixes #391945 (closed).

CREATED_ASC, CREATED_DESC, UPDATED_ASC, and UPDATED_DESC were not valid options for sorting, because are injected from the underlying type SortEnum but not handled by the resolver.

This MR fixes that 🙂

Screenshots or screen recordings

N.A.

How to set up and validate locally

  1. Create some timelogs if not already present
  2. Open GraphQL explorer (eg http://localhost:3000/-/graphql-explorer)
  3. Running a GraphQL query for timelogs, like the next one, should work for all available sort options:
{
  group(fullPath: "flightjs") {
    timelogs(sort: CREATED_ASC) {
      nodes {
        id
      }
    }
  }
}

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Merge request reports

Loading