From 903cb99cb784720a404671d4981e550909bced81 Mon Sep 17 00:00:00 2001
From: Brian DiChiara <122309362+bd-viget@users.noreply.github.com>
Date: Mon, 11 Dec 2023 08:50:28 -0600
Subject: [PATCH] #3 Auction Post Type (#59)
---
.phpcs.xml.dist | 4 +-
client-mu-plugins/goodbids/README.md | 5 +
client-mu-plugins/goodbids/composer.lock | 92 ++++++++----
.../goodbids/group_6570c1fa76181.json | 116 +++++++++++++++
.../goodbids/src/classes/Core.php | 18 ++-
.../src/classes/auctions/Auctions.php | 132 ++++++++++++++++++
.../goodbids/src/classes/network/Sites.php | 8 +-
composer.lock | 129 ++++++++++++-----
8 files changed, 433 insertions(+), 71 deletions(-)
create mode 100644 client-mu-plugins/goodbids/group_6570c1fa76181.json
create mode 100644 client-mu-plugins/goodbids/src/classes/auctions/Auctions.php
diff --git a/.phpcs.xml.dist b/.phpcs.xml.dist
index 027631d16..0188e5322 100644
--- a/.phpcs.xml.dist
+++ b/.phpcs.xml.dist
@@ -33,10 +33,10 @@
-
+
-
+
diff --git a/client-mu-plugins/goodbids/README.md b/client-mu-plugins/goodbids/README.md
index 095d79fb7..2252675bc 100644
--- a/client-mu-plugins/goodbids/README.md
+++ b/client-mu-plugins/goodbids/README.md
@@ -31,3 +31,8 @@ Returns the array of custom fields, based on the given context (create, edit, or
`goodbids()->admin->render_field( string $key, array $field, string $prefix, array $data )`
Renders an admin field based on the given field array. The `$prefix` and `$data` parameters are optional, but required for some field types.
+
+### Auction Functions
+
+`goodbids()->auctions->get_post_type()`
+Returns the auction post type slug.
diff --git a/client-mu-plugins/goodbids/composer.lock b/client-mu-plugins/goodbids/composer.lock
index dfc0fb4e9..d11befd08 100644
--- a/client-mu-plugins/goodbids/composer.lock
+++ b/client-mu-plugins/goodbids/composer.lock
@@ -912,29 +912,29 @@
},
{
"name": "phpcsstandards/phpcsextra",
- "version": "1.2.0",
+ "version": "1.2.1",
"source": {
"type": "git",
"url": "https://github.com/PHPCSStandards/PHPCSExtra.git",
- "reference": "78b2cae1e9de1c05f0416de6f9a658cbb83ac324"
+ "reference": "11d387c6642b6e4acaf0bd9bf5203b8cca1ec489"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/PHPCSStandards/PHPCSExtra/zipball/78b2cae1e9de1c05f0416de6f9a658cbb83ac324",
- "reference": "78b2cae1e9de1c05f0416de6f9a658cbb83ac324",
+ "url": "https://api.github.com/repos/PHPCSStandards/PHPCSExtra/zipball/11d387c6642b6e4acaf0bd9bf5203b8cca1ec489",
+ "reference": "11d387c6642b6e4acaf0bd9bf5203b8cca1ec489",
"shasum": ""
},
"require": {
"php": ">=5.4",
- "phpcsstandards/phpcsutils": "^1.0.8",
- "squizlabs/php_codesniffer": "^3.7.1"
+ "phpcsstandards/phpcsutils": "^1.0.9",
+ "squizlabs/php_codesniffer": "^3.8.0"
},
"require-dev": {
"php-parallel-lint/php-console-highlighter": "^1.0",
"php-parallel-lint/php-parallel-lint": "^1.3.2",
"phpcsstandards/phpcsdevcs": "^1.1.6",
"phpcsstandards/phpcsdevtools": "^1.2.1",
- "phpunit/phpunit": "^4.5 || ^5.0 || ^6.0 || ^7.0"
+ "phpunit/phpunit": "^4.5 || ^5.0 || ^6.0 || ^7.0 || ^8.0 || ^9.0"
},
"type": "phpcodesniffer-standard",
"extra": {
@@ -986,33 +986,33 @@
"type": "open_collective"
}
],
- "time": "2023-12-02T14:30:12+00:00"
+ "time": "2023-12-08T16:49:07+00:00"
},
{
"name": "phpcsstandards/phpcsutils",
- "version": "1.0.8",
+ "version": "1.0.9",
"source": {
"type": "git",
"url": "https://github.com/PHPCSStandards/PHPCSUtils.git",
- "reference": "69465cab9d12454e5e7767b9041af0cd8cd13be7"
+ "reference": "908247bc65010c7b7541a9551e002db12e9dae70"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/PHPCSStandards/PHPCSUtils/zipball/69465cab9d12454e5e7767b9041af0cd8cd13be7",
- "reference": "69465cab9d12454e5e7767b9041af0cd8cd13be7",
+ "url": "https://api.github.com/repos/PHPCSStandards/PHPCSUtils/zipball/908247bc65010c7b7541a9551e002db12e9dae70",
+ "reference": "908247bc65010c7b7541a9551e002db12e9dae70",
"shasum": ""
},
"require": {
"dealerdirect/phpcodesniffer-composer-installer": "^0.4.1 || ^0.5 || ^0.6.2 || ^0.7 || ^1.0",
"php": ">=5.4",
- "squizlabs/php_codesniffer": "^3.7.1 || 4.0.x-dev@dev"
+ "squizlabs/php_codesniffer": "^3.8.0 || 4.0.x-dev@dev"
},
"require-dev": {
"ext-filter": "*",
"php-parallel-lint/php-console-highlighter": "^1.0",
"php-parallel-lint/php-parallel-lint": "^1.3.2",
"phpcsstandards/phpcsdevcs": "^1.1.6",
- "yoast/phpunit-polyfills": "^1.0.5 || ^2.0.0"
+ "yoast/phpunit-polyfills": "^1.1.0 || ^2.0.0"
},
"type": "phpcodesniffer-standard",
"extra": {
@@ -1057,22 +1057,37 @@
"support": {
"docs": "https://phpcsutils.com/",
"issues": "https://github.com/PHPCSStandards/PHPCSUtils/issues",
+ "security": "https://github.com/PHPCSStandards/PHPCSUtils/security/policy",
"source": "https://github.com/PHPCSStandards/PHPCSUtils"
},
- "time": "2023-07-16T21:39:41+00:00"
+ "funding": [
+ {
+ "url": "https://github.com/PHPCSStandards",
+ "type": "github"
+ },
+ {
+ "url": "https://github.com/jrfnl",
+ "type": "github"
+ },
+ {
+ "url": "https://opencollective.com/php_codesniffer",
+ "type": "open_collective"
+ }
+ ],
+ "time": "2023-12-08T14:50:00+00:00"
},
{
"name": "squizlabs/php_codesniffer",
- "version": "3.7.2",
+ "version": "3.8.0",
"source": {
"type": "git",
- "url": "https://github.com/squizlabs/PHP_CodeSniffer.git",
- "reference": "ed8e00df0a83aa96acf703f8c2979ff33341f879"
+ "url": "https://github.com/PHPCSStandards/PHP_CodeSniffer.git",
+ "reference": "5805f7a4e4958dbb5e944ef1e6edae0a303765e7"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/ed8e00df0a83aa96acf703f8c2979ff33341f879",
- "reference": "ed8e00df0a83aa96acf703f8c2979ff33341f879",
+ "url": "https://api.github.com/repos/PHPCSStandards/PHP_CodeSniffer/zipball/5805f7a4e4958dbb5e944ef1e6edae0a303765e7",
+ "reference": "5805f7a4e4958dbb5e944ef1e6edae0a303765e7",
"shasum": ""
},
"require": {
@@ -1082,7 +1097,7 @@
"php": ">=5.4.0"
},
"require-dev": {
- "phpunit/phpunit": "^4.0 || ^5.0 || ^6.0 || ^7.0"
+ "phpunit/phpunit": "^4.0 || ^5.0 || ^6.0 || ^7.0 || ^8.0 || ^9.0"
},
"bin": [
"bin/phpcs",
@@ -1101,22 +1116,45 @@
"authors": [
{
"name": "Greg Sherwood",
- "role": "lead"
+ "role": "Former lead"
+ },
+ {
+ "name": "Juliette Reinders Folmer",
+ "role": "Current lead"
+ },
+ {
+ "name": "Contributors",
+ "homepage": "https://github.com/PHPCSStandards/PHP_CodeSniffer/graphs/contributors"
}
],
"description": "PHP_CodeSniffer tokenizes PHP, JavaScript and CSS files and detects violations of a defined set of coding standards.",
- "homepage": "https://github.com/squizlabs/PHP_CodeSniffer",
+ "homepage": "https://github.com/PHPCSStandards/PHP_CodeSniffer",
"keywords": [
"phpcs",
"standards",
"static analysis"
],
"support": {
- "issues": "https://github.com/squizlabs/PHP_CodeSniffer/issues",
- "source": "https://github.com/squizlabs/PHP_CodeSniffer",
- "wiki": "https://github.com/squizlabs/PHP_CodeSniffer/wiki"
+ "issues": "https://github.com/PHPCSStandards/PHP_CodeSniffer/issues",
+ "security": "https://github.com/PHPCSStandards/PHP_CodeSniffer/security/policy",
+ "source": "https://github.com/PHPCSStandards/PHP_CodeSniffer",
+ "wiki": "https://github.com/PHPCSStandards/PHP_CodeSniffer/wiki"
},
- "time": "2023-02-22T23:07:41+00:00"
+ "funding": [
+ {
+ "url": "https://github.com/PHPCSStandards",
+ "type": "github"
+ },
+ {
+ "url": "https://github.com/jrfnl",
+ "type": "github"
+ },
+ {
+ "url": "https://opencollective.com/php_codesniffer",
+ "type": "open_collective"
+ }
+ ],
+ "time": "2023-12-08T12:32:31+00:00"
},
{
"name": "wp-coding-standards/wpcs",
diff --git a/client-mu-plugins/goodbids/group_6570c1fa76181.json b/client-mu-plugins/goodbids/group_6570c1fa76181.json
new file mode 100644
index 000000000..6c84738c7
--- /dev/null
+++ b/client-mu-plugins/goodbids/group_6570c1fa76181.json
@@ -0,0 +1,116 @@
+{
+ "key": "group_6570c1fa76181",
+ "title": "Auction Settings",
+ "fields": [
+ {
+ "key": "field_657334958904f",
+ "label": "Auction Product",
+ "name": "auction_product",
+ "aria-label": "",
+ "type": "post_object",
+ "instructions": "",
+ "required": 1,
+ "conditional_logic": 0,
+ "wrapper": {
+ "width": "",
+ "class": "",
+ "id": ""
+ },
+ "post_type": [
+ "product"
+ ],
+ "post_status": [
+ "publish"
+ ],
+ "taxonomy": "",
+ "return_format": "object",
+ "multiple": 0,
+ "allow_null": 0,
+ "bidirectional": 0,
+ "ui": 1,
+ "bidirectional_target": []
+ },
+ {
+ "key": "field_6570c1fb429a8",
+ "label": "Auction Start",
+ "name": "auction_start",
+ "aria-label": "",
+ "type": "date_time_picker",
+ "instructions": "",
+ "required": 1,
+ "conditional_logic": 0,
+ "wrapper": {
+ "width": "",
+ "class": "",
+ "id": ""
+ },
+ "display_format": "m\/d\/Y g:i a",
+ "return_format": "Y-m-d H:i:s",
+ "first_day": 0
+ },
+ {
+ "key": "field_657334728904e",
+ "label": "Bid Increment",
+ "name": "bid_increment",
+ "aria-label": "",
+ "type": "number",
+ "instructions": "",
+ "required": 1,
+ "conditional_logic": 0,
+ "wrapper": {
+ "width": "",
+ "class": "",
+ "id": ""
+ },
+ "default_value": "",
+ "min": "",
+ "max": "",
+ "placeholder": "",
+ "step": "",
+ "prepend": "$",
+ "append": ".00"
+ },
+ {
+ "key": "field_657334428904d",
+ "label": "Auction Goal",
+ "name": "auction_goal",
+ "aria-label": "",
+ "type": "number",
+ "instructions": "",
+ "required": 0,
+ "conditional_logic": 0,
+ "wrapper": {
+ "width": "",
+ "class": "",
+ "id": ""
+ },
+ "default_value": "",
+ "min": "",
+ "max": "",
+ "placeholder": "",
+ "step": "",
+ "prepend": "$",
+ "append": ".00"
+ }
+ ],
+ "location": [
+ [
+ {
+ "param": "post_type",
+ "operator": "==",
+ "value": "gb-auction"
+ }
+ ]
+ ],
+ "menu_order": 0,
+ "position": "normal",
+ "style": "default",
+ "label_placement": "top",
+ "instruction_placement": "label",
+ "hide_on_screen": "",
+ "active": true,
+ "description": "",
+ "show_in_rest": 0,
+ "modified": 1702068952,
+ "private": true
+}
diff --git a/client-mu-plugins/goodbids/src/classes/Core.php b/client-mu-plugins/goodbids/src/classes/Core.php
index 72de6256b..b6d176120 100644
--- a/client-mu-plugins/goodbids/src/classes/Core.php
+++ b/client-mu-plugins/goodbids/src/classes/Core.php
@@ -9,6 +9,7 @@
namespace GoodBids;
use GoodBids\Admin\Admin;
+use GoodBids\Auctions\Auctions;
use GoodBids\Network\Sites;
use GoodBids\Plugins\ACF;
@@ -53,6 +54,12 @@ class Core {
*/
public Admin $admin;
+ /**
+ * @since 1.0.0
+ * @var Auctions
+ */
+ public Auctions $auctions;
+
/**
* Constructor
*
@@ -139,9 +146,9 @@ private function load_config() : bool {
*
* @param string $key Config Key.
*
- * @return mixed|null
+ * @return mixed
*/
- public function get_config( string $key ) {
+ public function get_config( string $key ) : mixed {
return $this->config[ $key ] ?? null;
}
@@ -193,9 +200,10 @@ private function load_modules() : void {
add_action(
'mu_plugin_loaded',
function () {
- $this->acf = new ACF();
- $this->sites = new Sites();
- $this->admin = new Admin();
+ $this->acf = new ACF();
+ $this->sites = new Sites();
+ $this->admin = new Admin();
+ $this->auctions = new Auctions();
}
);
}
diff --git a/client-mu-plugins/goodbids/src/classes/auctions/Auctions.php b/client-mu-plugins/goodbids/src/classes/auctions/Auctions.php
new file mode 100644
index 000000000..06e1e2d41
--- /dev/null
+++ b/client-mu-plugins/goodbids/src/classes/auctions/Auctions.php
@@ -0,0 +1,132 @@
+register_post_type();
+ }
+
+ /**
+ * Register the Auctions post type
+ *
+ * @since 1.0.0
+ *
+ * @return void
+ */
+ private function register_post_type() : void {
+ add_action(
+ 'init',
+ function () {
+ $labels = [
+ 'name' => _x( 'Auctions', 'Post Type General Name', 'goodbids' ),
+ 'singular_name' => _x( 'Auction', 'Post Type Singular Name', 'goodbids' ),
+ 'menu_name' => __( 'Auctions', 'goodbids' ),
+ 'name_admin_bar' => __( 'Auction', 'goodbids' ),
+ 'archives' => __( 'Auction Archives', 'goodbids' ),
+ 'attributes' => __( 'Auction Attributes', 'goodbids' ),
+ 'parent_item_colon' => __( 'Parent Auction:', 'goodbids' ),
+ 'all_items' => __( 'All Auctions', 'goodbids' ),
+ 'add_new_item' => __( 'Add New Auction', 'goodbids' ),
+ 'add_new' => __( 'Add New', 'goodbids' ),
+ 'new_item' => __( 'New Auction', 'goodbids' ),
+ 'edit_item' => __( 'Edit Auction', 'goodbids' ),
+ 'update_item' => __( 'Update Auction', 'goodbids' ),
+ 'view_item' => __( 'View Auction', 'goodbids' ),
+ 'view_items' => __( 'View Auctions', 'goodbids' ),
+ 'search_items' => __( 'Search Auction', 'goodbids' ),
+ 'not_found' => __( 'Not found', 'goodbids' ),
+ 'not_found_in_trash' => __( 'Not found in Trash', 'goodbids' ),
+ 'featured_image' => __( 'Featured Image', 'goodbids' ),
+ 'set_featured_image' => __( 'Set featured image', 'goodbids' ),
+ 'remove_featured_image' => __( 'Remove featured image', 'goodbids' ),
+ 'use_featured_image' => __( 'Use as featured image', 'goodbids' ),
+ 'insert_into_item' => __( 'Insert into auction', 'goodbids' ),
+ 'uploaded_to_this_item' => __( 'Uploaded to this auction', 'goodbids' ),
+ 'items_list' => __( 'Auctions list', 'goodbids' ),
+ 'items_list_navigation' => __( 'Auctions list navigation', 'goodbids' ),
+ 'filter_items_list' => __( 'Filter auctions list', 'goodbids' ),
+ ];
+
+ $rewrite = [
+ 'slug' => self::SINGULAR_SLUG,
+ 'with_front' => false,
+ 'pages' => true,
+ 'feeds' => true,
+ ];
+
+ $args = [
+ 'label' => __( 'Auction', 'goodbids' ),
+ 'description' => __( 'GoodBids Auction Custom Post Type', 'goodbids' ),
+ 'labels' => $labels,
+ 'supports' => array( 'title', 'editor', 'thumbnail', 'comments', 'revisions' ),
+ 'hierarchical' => false,
+ 'public' => true,
+ 'show_ui' => true,
+ 'show_in_menu' => true,
+ 'menu_position' => 5,
+ 'menu_icon' => 'dashicons-money-alt',
+ 'show_in_admin_bar' => true,
+ 'show_in_nav_menus' => true,
+ 'can_export' => true,
+ 'has_archive' => self::ARCHIVE_SLUG,
+ 'exclude_from_search' => false,
+ 'publicly_queryable' => true,
+ 'rewrite' => $rewrite,
+ 'capability_type' => 'page',
+ 'show_in_rest' => true,
+ 'rest_base' => self::SINGULAR_SLUG,
+ ];
+
+ register_post_type( self::POST_TYPE, $args );
+ }
+ );
+ }
+
+ /**
+ * Returns the Auction post type slug.
+ *
+ * @since 1.0.0
+ *
+ * @return string
+ */
+ public function get_post_type() : string {
+ return self::POST_TYPE;
+ }
+
+}
diff --git a/client-mu-plugins/goodbids/src/classes/network/Sites.php b/client-mu-plugins/goodbids/src/classes/network/Sites.php
index 1b38f5524..c781bda4d 100644
--- a/client-mu-plugins/goodbids/src/classes/network/Sites.php
+++ b/client-mu-plugins/goodbids/src/classes/network/Sites.php
@@ -320,13 +320,17 @@ private function save_edit_site_fields() : void {
* @param WP_Site $old_site Old site object.
*/
function ( WP_Site $new_site, WP_Site $old_site ) {
- check_admin_referer( 'edit-site' );
+ if ( defined( 'DOING_AJAX' ) && DOING_AJAX ) {
+ return;
+ }
- if ( empty( $_POST[ self::OPTION_SLUG ] ) ) { // phpcs:ignore
+ if ( empty( $_POST[ self::OPTION_SLUG ] ) ) {
// TODO: Log error.
return;
}
+ check_admin_referer( 'edit-site' );
+
$data = $_POST[ self::OPTION_SLUG ]; // phpcs:ignore
foreach ( $this->get_np_fields( 'edit' ) as $key => $field ) {
diff --git a/composer.lock b/composer.lock
index c64e2cd7e..558a49bab 100644
--- a/composer.lock
+++ b/composer.lock
@@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically"
],
- "content-hash": "4c4a58f7fc0e0376d89e7d3de00115d4",
+ "content-hash": "d3f1ad3a402c8e98b76ae1c4e156198b",
"packages": [],
"packages-dev": [
{
@@ -315,29 +315,29 @@
},
{
"name": "phpcsstandards/phpcsextra",
- "version": "1.1.1",
+ "version": "1.2.1",
"source": {
"type": "git",
"url": "https://github.com/PHPCSStandards/PHPCSExtra.git",
- "reference": "98bcdbacbda14b1db85f710b1853125726795bbc"
+ "reference": "11d387c6642b6e4acaf0bd9bf5203b8cca1ec489"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/PHPCSStandards/PHPCSExtra/zipball/98bcdbacbda14b1db85f710b1853125726795bbc",
- "reference": "98bcdbacbda14b1db85f710b1853125726795bbc",
+ "url": "https://api.github.com/repos/PHPCSStandards/PHPCSExtra/zipball/11d387c6642b6e4acaf0bd9bf5203b8cca1ec489",
+ "reference": "11d387c6642b6e4acaf0bd9bf5203b8cca1ec489",
"shasum": ""
},
"require": {
"php": ">=5.4",
- "phpcsstandards/phpcsutils": "^1.0.8",
- "squizlabs/php_codesniffer": "^3.7.1"
+ "phpcsstandards/phpcsutils": "^1.0.9",
+ "squizlabs/php_codesniffer": "^3.8.0"
},
"require-dev": {
"php-parallel-lint/php-console-highlighter": "^1.0",
"php-parallel-lint/php-parallel-lint": "^1.3.2",
"phpcsstandards/phpcsdevcs": "^1.1.6",
"phpcsstandards/phpcsdevtools": "^1.2.1",
- "phpunit/phpunit": "^4.5 || ^5.0 || ^6.0 || ^7.0"
+ "phpunit/phpunit": "^4.5 || ^5.0 || ^6.0 || ^7.0 || ^8.0 || ^9.0"
},
"type": "phpcodesniffer-standard",
"extra": {
@@ -372,35 +372,50 @@
],
"support": {
"issues": "https://github.com/PHPCSStandards/PHPCSExtra/issues",
+ "security": "https://github.com/PHPCSStandards/PHPCSExtra/security/policy",
"source": "https://github.com/PHPCSStandards/PHPCSExtra"
},
- "time": "2023-08-26T04:46:45+00:00"
+ "funding": [
+ {
+ "url": "https://github.com/PHPCSStandards",
+ "type": "github"
+ },
+ {
+ "url": "https://github.com/jrfnl",
+ "type": "github"
+ },
+ {
+ "url": "https://opencollective.com/php_codesniffer",
+ "type": "open_collective"
+ }
+ ],
+ "time": "2023-12-08T16:49:07+00:00"
},
{
"name": "phpcsstandards/phpcsutils",
- "version": "1.0.8",
+ "version": "1.0.9",
"source": {
"type": "git",
"url": "https://github.com/PHPCSStandards/PHPCSUtils.git",
- "reference": "69465cab9d12454e5e7767b9041af0cd8cd13be7"
+ "reference": "908247bc65010c7b7541a9551e002db12e9dae70"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/PHPCSStandards/PHPCSUtils/zipball/69465cab9d12454e5e7767b9041af0cd8cd13be7",
- "reference": "69465cab9d12454e5e7767b9041af0cd8cd13be7",
+ "url": "https://api.github.com/repos/PHPCSStandards/PHPCSUtils/zipball/908247bc65010c7b7541a9551e002db12e9dae70",
+ "reference": "908247bc65010c7b7541a9551e002db12e9dae70",
"shasum": ""
},
"require": {
"dealerdirect/phpcodesniffer-composer-installer": "^0.4.1 || ^0.5 || ^0.6.2 || ^0.7 || ^1.0",
"php": ">=5.4",
- "squizlabs/php_codesniffer": "^3.7.1 || 4.0.x-dev@dev"
+ "squizlabs/php_codesniffer": "^3.8.0 || 4.0.x-dev@dev"
},
"require-dev": {
"ext-filter": "*",
"php-parallel-lint/php-console-highlighter": "^1.0",
"php-parallel-lint/php-parallel-lint": "^1.3.2",
"phpcsstandards/phpcsdevcs": "^1.1.6",
- "yoast/phpunit-polyfills": "^1.0.5 || ^2.0.0"
+ "yoast/phpunit-polyfills": "^1.1.0 || ^2.0.0"
},
"type": "phpcodesniffer-standard",
"extra": {
@@ -445,9 +460,24 @@
"support": {
"docs": "https://phpcsutils.com/",
"issues": "https://github.com/PHPCSStandards/PHPCSUtils/issues",
+ "security": "https://github.com/PHPCSStandards/PHPCSUtils/security/policy",
"source": "https://github.com/PHPCSStandards/PHPCSUtils"
},
- "time": "2023-07-16T21:39:41+00:00"
+ "funding": [
+ {
+ "url": "https://github.com/PHPCSStandards",
+ "type": "github"
+ },
+ {
+ "url": "https://github.com/jrfnl",
+ "type": "github"
+ },
+ {
+ "url": "https://opencollective.com/php_codesniffer",
+ "type": "open_collective"
+ }
+ ],
+ "time": "2023-12-08T14:50:00+00:00"
},
{
"name": "sirbrillig/phpcs-variable-analysis",
@@ -509,16 +539,16 @@
},
{
"name": "squizlabs/php_codesniffer",
- "version": "3.7.2",
+ "version": "3.8.0",
"source": {
"type": "git",
- "url": "https://github.com/squizlabs/PHP_CodeSniffer.git",
- "reference": "ed8e00df0a83aa96acf703f8c2979ff33341f879"
+ "url": "https://github.com/PHPCSStandards/PHP_CodeSniffer.git",
+ "reference": "5805f7a4e4958dbb5e944ef1e6edae0a303765e7"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/ed8e00df0a83aa96acf703f8c2979ff33341f879",
- "reference": "ed8e00df0a83aa96acf703f8c2979ff33341f879",
+ "url": "https://api.github.com/repos/PHPCSStandards/PHP_CodeSniffer/zipball/5805f7a4e4958dbb5e944ef1e6edae0a303765e7",
+ "reference": "5805f7a4e4958dbb5e944ef1e6edae0a303765e7",
"shasum": ""
},
"require": {
@@ -528,7 +558,7 @@
"php": ">=5.4.0"
},
"require-dev": {
- "phpunit/phpunit": "^4.0 || ^5.0 || ^6.0 || ^7.0"
+ "phpunit/phpunit": "^4.0 || ^5.0 || ^6.0 || ^7.0 || ^8.0 || ^9.0"
},
"bin": [
"bin/phpcs",
@@ -547,35 +577,58 @@
"authors": [
{
"name": "Greg Sherwood",
- "role": "lead"
+ "role": "Former lead"
+ },
+ {
+ "name": "Juliette Reinders Folmer",
+ "role": "Current lead"
+ },
+ {
+ "name": "Contributors",
+ "homepage": "https://github.com/PHPCSStandards/PHP_CodeSniffer/graphs/contributors"
}
],
"description": "PHP_CodeSniffer tokenizes PHP, JavaScript and CSS files and detects violations of a defined set of coding standards.",
- "homepage": "https://github.com/squizlabs/PHP_CodeSniffer",
+ "homepage": "https://github.com/PHPCSStandards/PHP_CodeSniffer",
"keywords": [
"phpcs",
"standards",
"static analysis"
],
"support": {
- "issues": "https://github.com/squizlabs/PHP_CodeSniffer/issues",
- "source": "https://github.com/squizlabs/PHP_CodeSniffer",
- "wiki": "https://github.com/squizlabs/PHP_CodeSniffer/wiki"
+ "issues": "https://github.com/PHPCSStandards/PHP_CodeSniffer/issues",
+ "security": "https://github.com/PHPCSStandards/PHP_CodeSniffer/security/policy",
+ "source": "https://github.com/PHPCSStandards/PHP_CodeSniffer",
+ "wiki": "https://github.com/PHPCSStandards/PHP_CodeSniffer/wiki"
},
- "time": "2023-02-22T23:07:41+00:00"
+ "funding": [
+ {
+ "url": "https://github.com/PHPCSStandards",
+ "type": "github"
+ },
+ {
+ "url": "https://github.com/jrfnl",
+ "type": "github"
+ },
+ {
+ "url": "https://opencollective.com/php_codesniffer",
+ "type": "open_collective"
+ }
+ ],
+ "time": "2023-12-08T12:32:31+00:00"
},
{
"name": "wp-coding-standards/wpcs",
- "version": "3.0.0",
+ "version": "3.0.1",
"source": {
"type": "git",
"url": "https://github.com/WordPress/WordPress-Coding-Standards.git",
- "reference": "bb792cb331472b82c5d7f28fb9b8ec2d20f68826"
+ "reference": "b4caf9689f1a0e4a4c632679a44e638c1c67aff1"
},
"dist": {
"type": "zip",
- "url": "https://api.github.com/repos/WordPress/WordPress-Coding-Standards/zipball/bb792cb331472b82c5d7f28fb9b8ec2d20f68826",
- "reference": "bb792cb331472b82c5d7f28fb9b8ec2d20f68826",
+ "url": "https://api.github.com/repos/WordPress/WordPress-Coding-Standards/zipball/b4caf9689f1a0e4a4c632679a44e638c1c67aff1",
+ "reference": "b4caf9689f1a0e4a4c632679a44e638c1c67aff1",
"shasum": ""
},
"require": {
@@ -622,7 +675,13 @@
"source": "https://github.com/WordPress/WordPress-Coding-Standards",
"wiki": "https://github.com/WordPress/WordPress-Coding-Standards/wiki"
},
- "time": "2023-08-21T14:28:38+00:00"
+ "funding": [
+ {
+ "url": "https://opencollective.com/thewpcc/contribute/wp-php-63406",
+ "type": "custom"
+ }
+ ],
+ "time": "2023-09-14T07:06:09+00:00"
}
],
"aliases": [],
@@ -631,8 +690,8 @@
"prefer-stable": false,
"prefer-lowest": false,
"platform": {
- "php": ">=8.0"
+ "php": ">=8.1"
},
"platform-dev": [],
- "plugin-api-version": "2.3.0"
+ "plugin-api-version": "2.6.0"
}