Skip to content

Fix b8 migration regressions, v2.3.5 milestone bugs, and convert to the property API - #533

Open
sultann wants to merge 10 commits into
release/2.3.5from
fix/b8-migration-followups
Open

Fix b8 migration regressions, v2.3.5 milestone bugs, and convert to the property API#533
sultann wants to merge 10 commits into
release/2.3.5from
fix/b8-migration-followups

Conversation

@sultann

@sultann sultann commented Jun 18, 2026

Copy link
Copy Markdown
Contributor

Summary

Follow-up to the bytekit -> b8 model migration on release/2.3.5. Fixes regressions the migration introduced, closes the three v2.3.5 milestone bugs, and converts the free plugin's own code off the deprecated getter/setter shims onto the new property API. The deprecated shims themselves are intentionally kept — master Pro (1.4.6) and the Legacy API add-on still call them.

All changes verified against the PHPUnit suite (89 tests green) and phpcs (clean).

Migration regressions

  • Keys "filter by customer" silently broken — b8 dropped the old customer_id -> order_id IN (...) translation. Restored as a query_args filter on the Key model (honors the framework's empty-IN-is-ignored contract). +2 tests.
  • enable_product never fired — the hook was wc_serial_numbers_key_insert, but b8 fires wc_serial_numbers_key_inserted and passes the model (not an id). Rewired and signature fixed. Removed three dead encrypt/decrypt action hooks the model now owns directly. +1 test.
  • wcsn_order_replace_key counted failed saves as successsave() returns a truthy WP_Error on failure; now checks ! is_wp_error().

v2.3.5 milestone bugs

Deprecated API -> property API conversion

Converted ~90 internal call sites across 11 files (REST, admin screens/list tables, templates, PDF integrations, core helpers) from $key->get_*() / $key->set_*() to property access ($key->serial_key, $key->status = ..., etc.). No behavior change; the deprecated methods remain for external consumers.

Pro compatibility

Master Pro 1.4.6's full call surface into the free plugin (wcsn_* functions, Key/Activation getters, where_query, the generator/duplicate filters, the REST activations contract) is satisfied. The only break was #532, now fixed free-side.

Closes #527, #531, #532.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant