Skip to content

Development - #1356

Merged
kushh23 merged 25 commits into
masterfrom
development
Jul 30, 2026
Merged

Development#1356
kushh23 merged 25 commits into
masterfrom
development

Conversation

@Soare-Robert-Daniel

@Soare-Robert-Daniel Soare-Robert-Daniel commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Linked issues

This release will close the following issues once merged:

Public changelog

  • Fixed charts using a database source saving the results of the previous query, so a saved chart no longer differs from the data shown in the editor.
  • Updated dependencies
  • Enhanced security — fixed unauthorized chart_data REST access.

lucadobrescu and others added 11 commits July 10, 2026 13:39
Save the active database query before the chart form closes so one-time imports cannot retain stale preview data.

Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Wait for the query editor to initialize before opening it, navigate to
the chart post via ?p= so the check works under any permalink structure,
and retry the front-end chart assertion since chart scripts lazy-load
on user interaction.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
The chart_data REST field callback only checked the generic edit_posts
capability, so any contributor could read the full backend configuration
of any chart (data source query, settings, JSON endpoint auth headers)
via GET /wp-json/wp/v2/visualizer/{id}.

Check edit_post on the requested chart instead, so access follows the
standard post capability map (author or edit_others_posts).

Fixes Codeinwp/visualizer-pro#605

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Charts are force-published on save, and Contributors lack
edit_published_posts, so a bare edit_post check locks chart authors out
of their own charts in the Gutenberg block. Use the existing
Visualizer_Module::can_edit_chart() helper, which allows the chart
owner with edit_posts while still rejecting other users' charts.

Covers Copilot review feedback on #1348.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Bumps [phpstan/phpstan](https://github.com/phpstan/phpstan-phar-composer-source) from 2.1.54 to 2.2.6.
- [Commits](https://github.com/phpstan/phpstan-phar-composer-source/commits)

---
updated-dependencies:
- dependency-name: phpstan/phpstan
  dependency-version: 2.2.6
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…1350)

Bumps [wp-coding-standards/wpcs](https://github.com/WordPress/WordPress-Coding-Standards) from 3.3.0 to 3.4.1.
- [Release notes](https://github.com/WordPress/WordPress-Coding-Standards/releases)
- [Changelog](https://github.com/WordPress/WordPress-Coding-Standards/blob/develop/CHANGELOG.md)
- [Commits](WordPress/WordPress-Coding-Standards@3.3.0...3.4.1)

---
updated-dependencies:
- dependency-name: wp-coding-standards/wpcs
  dependency-version: 3.4.1
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [codeinwp/themeisle-sdk](https://github.com/Codeinwp/themeisle-sdk) from 3.3.55 to 3.3.57.
- [Release notes](https://github.com/Codeinwp/themeisle-sdk/releases)
- [Changelog](https://github.com/Codeinwp/themeisle-sdk/blob/v3.3.57/CHANGELOG.md)
- [Commits](Codeinwp/themeisle-sdk@v3.3.55...v3.3.57)

---
updated-dependencies:
- dependency-name: codeinwp/themeisle-sdk
  dependency-version: 3.3.57
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
@Soare-Robert-Daniel Soare-Robert-Daniel added the pr-checklist-skip Allow this Pull Request to skip checklist. label Jul 29, 2026
@pirate-bot

pirate-bot commented Jul 29, 2026

Copy link
Copy Markdown
Contributor

Plugin build for baf67a3 is ready 🛎️!

Copilot AI and others added 14 commits July 29, 2026 12:13
Co-authored-by: selul <3330746+selul@users.noreply.github.com>
Fix stale database data after saving charts
fix: check per-chart edit_post capability in chart_data REST field
…1314)

Bumps [dealerdirect/phpcodesniffer-composer-installer](https://github.com/PHPCSStandards/composer-installer) from 1.2.0 to 1.2.1.
- [Release notes](https://github.com/PHPCSStandards/composer-installer/releases)
- [Changelog](https://github.com/PHPCSStandards/composer-installer/blob/main/CHANGELOG.md)
- [Commits](PHPCSStandards/composer-installer@v1.2.0...v1.2.1)

---
updated-dependencies:
- dependency-name: dealerdirect/phpcodesniffer-composer-installer
  dependency-version: 1.2.1
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…o-gate

fix: gate AI Builder db_query behind super-admin + Pro to match classic path
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
Co-authored-by: Cursor <cursoragent@cursor.com>
The suite passed identically with can_edit_chart() reverted to
current_user_can( 'edit_post' ): every case it exercised agreed under both
checks. Add the two rows that differ — a contributor's own published chart
(allowed only by the author branch) and a contributor's own non-chart post
(allowed only by edit_post) — plus a workflow start/poll test that pins the
transient binding, so a no-op set_transient() no longer passes.

Start the e2e login contexts from an empty storage state. browser.newContext()
inherits the project's admin cookies, so a login that silently failed left the
requests running as admin; that also drops wordpress_test_cookie, hence no
testcookie field. Delete the chart the contributor spec creates.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
fix: enforce per-chart authorization in AI Builder endpoints
@kushh23
kushh23 merged commit 7807ac9 into master Jul 30, 2026
8 of 9 checks passed
@pirate-bot

Copy link
Copy Markdown
Contributor

🎉 This PR is included in version 4.0.7 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

@pirate-bot pirate-bot added the released Indicate that an issue has been resolved and released in a particular version of the product. label Jul 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

compatibility-reviewed pr-checklist-skip Allow this Pull Request to skip checklist. released Indicate that an issue has been resolved and released in a particular version of the product.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Database source table can differ from Show Results after One-time import

6 participants