---
title: "Stitcher.io"
url: https://daily.dev/posts/stitcher-io-jgdolzw3r
source_url: https://stitcher.io/blog/reducing-code-motion
type: article
source: "stitcher.io"
published: 2025-10-22T11:49:43.685Z
updated: 2025-10-22T11:50:09.172Z
tags: ["database", "architecture", "php"]
reading_time: 4
upvotes: 44
comments: 0
language: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Stitcher.io

**[stitcher.io](https://daily.dev/sources/stitcher)** · 4 min read · 44 upvotes · 0 comments

## Summary

A refactoring case study that simplified a content scheduling system by eliminating a state transition and cron job. The original design used three states (PENDING, SCHEDULED, PUBLISHED) with automated transitions, requiring cron jobs, console commands, and complex logic. The refactor removed the SCHEDULED state and added a future-dated publicationDate field to PUBLISHED posts, using a SQL query to find available time slots. This eliminated moving parts like cron jobs and automatic state transitions, trading one type of complexity for another. The key insight: modeling software directly from human processes doesn't always yield the simplest technical solution.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://stitcher.io/blog/reducing-code-motion>

## Similar posts on daily.dev

- [How I auto-publish scheduled posts with a Cloudflare Worker cron](https://daily.dev/posts/how-i-auto-publish-scheduled-posts-with-a-cloudflare-worker-cron-0tvkhx5nx) · Flavio Copes · 2 upvotes · 0 comments

---

Tags: [#database](https://daily.dev/tags/database), [#architecture](https://daily.dev/tags/architecture), [#php](https://daily.dev/tags/php)

[View this post on daily.dev](https://daily.dev/posts/stitcher-io-jgdolzw3r)
