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

bleedingdeacons / amber / 35583190513
92%

Build:
DEFAULT BRANCH: main
Ran 21 Sep 2026 09:28AM UTC
Jobs 1
Files 34
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

21 Sep 2026 09:25AM UTC coverage: 92.297% (+0.07%) from 92.231%
35583190513

push

github

web-flow
fix: fall back and warn when the meeting config omits GROUP_POST_TYPE (#71)

Follow-up to [tsml-for-unity#81](https://github.com/bleedingdeacons/tsml-for-unity/pull/81), which published the key. This hardens the
consumer so the same class of bug can't hide again.

## The problem

`searchJoin()` read `GROUP_POST_TYPE` out of the meeting config with no default.
When the provider didn't publish it, that wasn't an error PHP stops for — it was
an undefined array key that interpolated into the join as:

```sql
AND group_post.post_type = ''
```

No row matches that, so the group half of the search returned nothing while the
screen still looked like it worked. Measured on the test bed, that branch matched
**0** meetings where it should have matched **1**.

## The fix

Fall back to a named default and log a warning once per request, so the
misconfiguration is noisy instead of invisible.

**Why a fallback rather than skipping the join:** `searchWhere()` references the
`group_post` alias unconditionally. A join that isn't added leaves the WHERE
pointing at a table the query doesn't have — invalid SQL. The two have to agree,
so the join must always be supplied.

The default is explicitly *not* the source of truth — the value belongs to
whichever plugin provides meetings, and TSML for Unity now publishes it.

## Why the existing test didn't catch it

`MeetingAdminTest::setUp()` passed a `GROUP_POST_TYPE` that the real config never
published, and the assertion only checked that the join mentioned `group_post` —
never that it carried a usable post type. Both are asserted now, plus a
missing-key case that fails without this change.

## Verified

Full gate sequence green: validate, PHPStan level 8, 67 tests, PHPCS,
build:production.

4110 of 4453 relevant lines covered (92.3%)

4.14 hits per line

Coverage Regressions

Lines Coverage ∆ File
2
97.5
0.2% amber/amber/src/Admin/Meetings/MeetingAdmin.php
Jobs
ID Job ID Ran Files Coverage
1 35583190513.1 21 Sep 2026 09:28AM UTC 34
92.3
GitHub Action Run
Source Files on build 35583190513
  • Tree
  • List 34
  • Changed 2
  • Source Changed 0
  • Coverage Changed 2
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #35583190513
  • 8d918072 on github
  • Prev Build on main (#35543098057)
  • Next Build on main (#35759419728)
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