Skip to content

[2.x] fix: migrate GDPR data type to Flarum 2.x API#67

Merged
imorland merged 2 commits into
2.xfrom
im/gdpr-data-refactor
Mar 5, 2026
Merged

[2.x] fix: migrate GDPR data type to Flarum 2.x API#67
imorland merged 2 commits into
2.xfrom
im/gdpr-data-refactor

Conversation

@imorland

@imorland imorland commented Mar 5, 2026

Copy link
Copy Markdown
Member

Summary

  • Replaces src/Gdpr/UserBioData.php (1.x DataType interface) with src/Data/UserBioData.php (2.x Type base class)
  • Declares bio as a PII field via piiFields() — the 2.x base class handles anonymize/delete automatically
  • Relies on the core GDPR user table export for bio data (no separate export file needed)
  • Updates extend.php reference from Gdpr\UserBioData to Data\UserBioData

Test plan

  • Enable flarum-gdpr extension alongside this one
  • Submit a GDPR export request — verify bio data appears in the user table export
  • Submit a GDPR anonymize request — verify bio column is cleared for the user
  • Submit a GDPR delete request — verify bio column is cleared before user deletion

🤖 Generated with Claude Code

Replaces the 1.x `DataType` interface implementation with a 2.x `Type`
base class subclass in `Data\UserBioData`. Uses `piiFields()` to declare
the `bio` column for automatic anonymize/delete handling, and relies on
the core GDPR user table export for bio data inclusion.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@imorland imorland requested a review from a team as a code owner March 5, 2026 07:59
@imorland imorland changed the title fix: migrate GDPR data type to Flarum 2.x API [2.x] fix: migrate GDPR data type to Flarum 2.x API Mar 5, 2026
@imorland imorland merged commit 741530a into 2.x Mar 5, 2026
32 checks passed
@imorland imorland deleted the im/gdpr-data-refactor branch March 5, 2026 08:03
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