It shows unpublished post at GET /post #128

Closed
opened 2025-08-12 16:07:18 +08:00 by squid · 0 comments
Owner

Query

curl -s https://squidspirit.com/api/post | jq 'map({id, published_time})'

As-is

[
  {
    "id": 1,
    "published_time": "2025-07-25T08:39:34.489007+00:00"
  },
  {
    "id": 2,
    "published_time": "2025-08-05T22:11:05.796074+00:00"
  },
  {
    "id": 4,
    "published_time": "2025-08-07T13:26:00.674114+00:00"
  },
  {
    "id": 5,
    "published_time": null
  }
]

To-be

[
  {
    "id": 1,
    "published_time": "2025-07-25T08:39:34.489007+00:00"
  },
  {
    "id": 2,
    "published_time": "2025-08-05T22:11:05.796074+00:00"
  },
  {
    "id": 4,
    "published_time": "2025-08-07T13:26:00.674114+00:00"
  }
]
## Query ```bash curl -s https://squidspirit.com/api/post | jq 'map({id, published_time})' ``` ## As-is ```json [ { "id": 1, "published_time": "2025-07-25T08:39:34.489007+00:00" }, { "id": 2, "published_time": "2025-08-05T22:11:05.796074+00:00" }, { "id": 4, "published_time": "2025-08-07T13:26:00.674114+00:00" }, { "id": 5, "published_time": null } ] ``` ## To-be ```json [ { "id": 1, "published_time": "2025-07-25T08:39:34.489007+00:00" }, { "id": 2, "published_time": "2025-08-05T22:11:05.796074+00:00" }, { "id": 4, "published_time": "2025-08-07T13:26:00.674114+00:00" } ] ```
squid added this to the 0.3 milestone 2025-08-12 16:07:18 +08:00
squid added the
bug
dev
backend
labels 2025-08-12 16:07:18 +08:00
squid added this to the Pre-release Development Plan project 2025-08-12 16:07:18 +08:00
squid moved this to In Progress in Pre-release Development Plan on 2025-08-12 16:07:21 +08:00
squid added reference BLOG-128_fix_unpublished_posts_query 2025-08-12 16:16:25 +08:00
squid closed this issue 2025-08-12 21:58:25 +08:00
squid moved this to Done in Pre-release Development Plan on 2025-08-12 22:00:58 +08:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: squid/blog#128
No description provided.