Skip to content
This repository was archived by the owner on Feb 5, 2026. It is now read-only.

Remove duplicate function keyword causing syntax error#135

Merged
gziolo merged 3 commits intoWordPress:trunkfrom
hmbashar:trunk
Nov 7, 2025
Merged

Remove duplicate function keyword causing syntax error#135
gziolo merged 3 commits intoWordPress:trunkfrom
hmbashar:trunk

Conversation

@hmbashar
Copy link
Contributor

@hmbashar hmbashar commented Nov 6, 2025

The callback my_plugin_register_abilities had function function declared, which caused a fatal syntax error. Removed the extra function keyword so the ability registers correctly according to the Abilities API docs.

The callback `my_plugin_register_abilities` had `function function` declared,
which caused a fatal syntax error. Removed the extra `function` keyword so the
ability registers correctly according to the Abilities API docs.
@github-actions
Copy link

github-actions bot commented Nov 6, 2025

The following accounts have interacted with this PR and/or linked issues. I will continue to update these lists as activity occurs. You can also manually ask me to refresh this list by adding the props-bot label.

If you're merging code through a pull request on GitHub, copy and paste the following into the bottom of the merge commit message.

Co-authored-by: hmbashar <hmbashar@git.wordpress.org>
Co-authored-by: gziolo <gziolo@git.wordpress.org>

To understand the WordPress project's expectations around crediting contributors, please review the Contributor Attribution page in the Core Handbook.

@codecov
Copy link

codecov bot commented Nov 6, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 80.39%. Comparing base (e7c6cf4) to head (63f4264).
⚠️ Report is 1 commits behind head on trunk.

Additional details and impacted files
@@            Coverage Diff            @@
##              trunk     #135   +/-   ##
=========================================
  Coverage     80.39%   80.39%           
  Complexity      178      178           
=========================================
  Files            20       20           
  Lines          1474     1474           
  Branches        120      119    -1     
=========================================
  Hits           1185     1185           
  Misses          289      289           
Flag Coverage Δ
javascript 94.31% <ø> (ø)
unit 76.31% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Updated the import syntax from `import { getAbilities } from \`@wordpress/abilities\`;`
to use standard single quotes (`import { getAbilities } from '@wordpress/abilities';`)
for consistency with JavaScript conventions and project formatting.
@gziolo gziolo added the [Type] Developer Documentation Improvements or additions to documentation label Nov 6, 2025
@gziolo gziolo added this to the WP 6.9 milestone Nov 6, 2025
@gziolo gziolo enabled auto-merge (squash) November 7, 2025 14:21
@gziolo gziolo merged commit d9440e5 into WordPress:trunk Nov 7, 2025
20 checks passed
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

[Type] Developer Documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants