Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 5 additions & 6 deletions .phpcs.xml.dist
Original file line number Diff line number Diff line change
Expand Up @@ -44,13 +44,12 @@
</rule>

<!--
DONOTCACHEPAGE is the cross-plugin convention page caches look for; the
point is that other plugins recognise it, so it cannot be prefixed.
The DONOTCACHEPAGE exemption is not here. It lives on the two define()
calls as phpcs:ignore annotations, because an exclusion written here
only applies to this ruleset — Plugin Check runs its own, and reports
the constant to the reviewer. An annotation travels with the code and
is the route Plugin Check documents for a false positive.
-->
<rule ref="WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedConstantFound">
<exclude-pattern>/includes/class-citecue-proxy\.php</exclude-pattern>
<exclude-pattern>/includes/class-citecue-llms-txt\.php</exclude-pattern>
</rule>

<!-- "llms.txt" is a filename and stays lowercase in prose. -->
<rule ref="Generic.Commenting.DocComment.ShortNotCapital">
Expand Down
4 changes: 2 additions & 2 deletions citecue.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* Plugin Name: CiteCue AI Auto-Fix
* Plugin URI: https://github.com/citecue/wordpress-plugin
* Description: Serves CiteCue-optimized versions of your pages to AI bots and crawlers, publishes your llms.txt, and lets CiteCue push brand-building draft content into WordPress.
* Version: 1.0.2
* Version: 1.0.3
* Requires at least: 5.8
* Requires PHP: 7.4
* Author: CiteCue
Expand Down Expand Up @@ -56,7 +56,7 @@ static function () {
return;
}

define( 'CITECUE_VERSION', '1.0.2' );
define( 'CITECUE_VERSION', '1.0.3' );
define( 'CITECUE_PLUGIN_FILE', __FILE__ );
define( 'CITECUE_PLUGIN_DIR', plugin_dir_path( __FILE__ ) );

Expand Down
1 change: 1 addition & 0 deletions includes/class-citecue-llms-txt.php
Original file line number Diff line number Diff line change
Expand Up @@ -197,6 +197,7 @@ private function is_llms_txt_request() {
*/
private function serve( $body ) {
if ( ! defined( 'DONOTCACHEPAGE' ) ) {
// phpcs:ignore WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedConstantFound -- the cross-plugin constant page caches look for; prefixing it would mean no cache ever sees it.
define( 'DONOTCACHEPAGE', true );
}

Expand Down
1 change: 1 addition & 0 deletions includes/class-citecue-proxy.php
Original file line number Diff line number Diff line change
Expand Up @@ -327,6 +327,7 @@ private function current_url() {
*/
private function serve( $body, $mode, $stale ) {
if ( ! defined( 'DONOTCACHEPAGE' ) ) {
// phpcs:ignore WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedConstantFound -- the cross-plugin constant page caches look for; prefixing it would mean no cache ever sees it.
define( 'DONOTCACHEPAGE', true );
}

Expand Down
5 changes: 4 additions & 1 deletion readme.txt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Tags: ai, llms.txt, gptbot, ai-seo, woocommerce
Requires at least: 5.8
Tested up to: 7.0
Requires PHP: 7.4
Stable tag: 1.0.2
Stable tag: 1.0.3
License: GPLv2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html

Expand Down Expand Up @@ -100,6 +100,9 @@ The plugin folder is now citecue-ai-auto-fix. If you installed 1.0.0 by uploadin

== Changelog ==

= 1.0.3 =
* No functional change. Annotates the DONOTCACHEPAGE definitions so code-quality tooling stops reporting a naming-convention violation the constant cannot avoid — page caches look for that exact name.

= 1.0.2 =
* Translations no longer depend on the plugin loading them by hand; WordPress.org supplies them for the plugin slug.
* The requested URL is sanitized on the way to CiteCue in a way that preserves percent-encoding, so pages with accented or non-Latin characters in the address are served and cached under the address they actually have.
Expand Down
Loading