Skip to content
This repository was archived by the owner on Jan 3, 2026. It is now read-only.
This repository was archived by the owner on Jan 3, 2026. It is now read-only.

/list Endpoint Does Not Filter Logs by User ID #200

@Alb11747

Description

@Alb11747

Description

The /list endpoint in JustLog does not correctly filter logs by the userid parameter. Instead of returning logs specific to the provided user ID, it returns logs for the entire channel.

Steps to Reproduce

  1. Make a GET request to https://justlog.alb11747.com/list?channel=fobm4ster&userid=31062476.

    • Expected: Logs filtered by the specified user ID.
    • Actual: Logs for the entire channel.

    Sample Output:

    {
      "availableLogs": [
        {"year": "2024", "month": "3"},
        {"year": "2024", "month": "2"},
        {"year": "2024", "month": "1"},
        {"year": "2023", "month": "12"}
      ]
    }
  2. Make a GET request to https://justlog.alb11747.com/list?channelid=31062476&userid=31062476.

    • Expected: Logs filtered by the specified user ID.
    • Actual: Logs for the entire channel.

    Sample Output:

    {
      "availableLogs": [
        {"year": "2024", "month": "3"},
        {"year": "2024", "month": "2"},
        {"year": "2024", "month": "1"},
        {"year": "2023", "month": "12"}
      ]
    }
  3. Make a GET request to https://justlog.alb11747.com/list?username=fobm4ster&channelid=31062476.

    • This call correctly returns logs filtered by the username and channel ID.

    Sample Output:

    {
      "availableLogs": [
        {"year": "2023", "month": "12", "day": "23"},
        {"year": "2023", "month": "12", "day": "12"},
        {"year": "2023", "month": "12", "day": "24"}
      ]
    }

Expected Behavior

The /list endpoint should filter logs based on the userid parameter when provided, similar to how it filters based on the username and channelid parameters.

Actual Behavior

The /list endpoint ignores the userid parameter and returns logs for the entire channel.

Additional Information

  • JustLog version: ghcr.io/gempir/justlog:latest@sha256:b414506c7da33c958b831f29d0d7fc947a17bd9f55c09b79d05020b1c53765d4

Possible Solution

It appears that the userid parameter is not being properly handled in the query logic for the /list endpoint. A review of the parameter parsing and filtering logic may be necessary to resolve this issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions