• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

timber / timber / 42248615032
91%
master: 93%

Build:
Build:
LAST BUILD BRANCH: dependabot/github_actions/WyriHaximus/github-action-composer-php-versions-in-range-2.2.0
DEFAULT BRANCH: master
Ran 06 Nov 2026 04:11PM UTC
Jobs 1
Files 70
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

06 Nov 2026 04:02PM UTC coverage: 90.163% (+0.06%) from 90.106%
42248615032

push

travis-ci

web-flow
fix: Keep cached post content correct for pages and excerpts (#3295)

* fix(post): only cache and reuse full content without removed blocks

content(1) decremented $page before the cache-write check, so the first
page of paged content was stored as the full content. The cache read also
ignored $remove_blocks and ran before the timber/post/content/remove_blocks
filter, so content(0, -1, true) and filter-driven removal returned the
cached content with its dynamic blocks.

Index the page without changing $page, and resolve the filter before the
cache read, which now uses the same condition as the cache write.

* refactor(post): share the content cache condition between read and write

* fix(post): cast the content page to an integer

Since the page is no longer decremented in place, `$pages[$page - 1]` threw a TypeError for a non-numeric page such as `post.content('abc')`. Casting once at the top restores the previous behaviour (full content) and makes the cache check `$page == 0` unambiguous under PHP 8.

* test(post): cover out-of-range content pages

A negative page or a page after the last one now returns the full content. Cover it with a test and document it in the docblock of content().

* test(post): assert the first page contains its content

testPagedContentDoesNotPoisonContentCache only checked that the first page didn't contain the second one, which an empty string would also satisfy.

---------

Co-authored-by: Dominic Rubas <1042243+rubas@users.noreply.github.com>
Co-authored-by: Nicolas Lemoine <nico.lemoine@gmail.com>

6 of 6 new or added lines in 1 file covered. (100.0%)

1 existing line in 1 file now uncovered.

4757 of 5276 relevant lines covered (90.16%)

68.33 hits per line

Coverage Regressions

Lines Coverage ∆ File
1
94.67
0.0% src/Post.php
Jobs
ID Job ID Ran Files Coverage
1 42248615032.1 06 Nov 2026 04:11PM UTC 70
90.16
Travis Job
Source Files on build 42248615032
  • Tree
  • List 70
  • Changed 2
  • Source Changed 1
  • Coverage Changed 2
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Travis Build #42248615032
  • 398883f5 on github
  • Prev Build on 2.x (#36821864128)
  • Next Build on 2.x (#42269296138)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc