Skip to content

Commit

Permalink
Merge branch 'release/0.21.0' into master
Browse files Browse the repository at this point in the history
  • Loading branch information
SeanDS committed Sep 6, 2020
2 parents e62fbea + eea6a06 commit 8ea9366
Show file tree
Hide file tree
Showing 11 changed files with 119 additions and 269 deletions.
45 changes: 28 additions & 17 deletions ssl-alp/README.txt
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
=== Academic Labbook ===
Contributors: seanleavey
Tags: logbook, coauthor, revisions, references, latex, tex, mathematics, wiki
Requires at least: 5.1.0
Tested up to: 5.4.1
Requires at least: 5.5.0
Tested up to: 5.5.1
Requires PHP: 7.0.0
Stable tag: 0.20.2
Stable tag: 0.21.0
License: GNU General Public License v3 or later
License URI: LICENCE

Expand Down Expand Up @@ -79,17 +79,27 @@ on the ALP website.

== Changelog ==

= 0.21.0 =
- WordPress 5.5 now required.
- Renamed deprecated function and hook calls to reflect [changes in core](https://make.wordpress.org/core/2020/07/23/codebase-language-improvements-in-5-5/).
- Inventory can now be hierarchical and use the post children block.
- Remove ability in REST API to view other users' post read flags (this was
never used by the front end).

= 0.20.2 =
- Have rebuild coauthors tool remove coauthor terms for users who no longer exist on the site.
- Have rebuild coauthors tool remove coauthor terms for users who no longer
exist on the site.
- Update some URLs pointing to https://alp.attackllama.com/.

= 0.20.1 =
- Add extra check when adding Unread Posts button to admin bar.
- Use better hook for adding Unread Posts to admin bar..
- Use better hook for adding Unread Posts to admin bar.
- Various bug fixes:
- Null check for terms in update_coauthor_term; occasionally we've seen the term doesn't exist
- Null check for terms in update_coauthor_term; occasionally we've seen the
term doesn't exist
- Null check for when an old revision has been deleted
- Check that ALP is active on blogs when adding coauthor terms on login when ALP is installed in a network but not network active
- Check that ALP is active on blogs when adding coauthor terms on login when
ALP is installed in a network but not network active
- Stop CSS revisions appearing in the Recent Revisions widget.

= 0.20.0 =
Expand Down Expand Up @@ -217,25 +227,26 @@ on the ALP website.
- Removed invalid coauthors attached to posts on save.

= 0.13.1 =
- Added support for advanced searches, letting users search posts by multiple coauthors, categories
and tags, and dates.
- Added setting to control display of advanced search tools to non-logged-in users.
- Added support for advanced searches, letting users search posts by multiple
coauthors, categories and tags, and dates.
- Added setting to control display of advanced search tools to non-logged-in
users.

= 0.13.0 =
- Added support for read flags, letting users keep track of posts they've read or not read and
allowing them to change this flag per-post and view a list of unread posts (requires Labbook
theme 1.1.0 or greater for front-end support).
- Added support for read flags, letting users keep track of posts they've read
or not read and allowing them to change this flag per-post and view a list of
unread posts (requires Labbook theme 1.1.0 or greater for front-end support).
- Fixed bug whereby coauthors were sent notifications for their own comments.
- Fixed bug with user widget in non-dropdown mode not showing all authors, and with dropdown mode
showing authors with zero posts.
- Fixed bug with user widget in non-dropdown mode not showing all authors, and
with dropdown mode showing authors with zero posts.
- Removed new default media file feature until Gutenberg bug is fixed.
- Updated KaTeX to 0.10.1.

= 0.12.3 =
- Set new default (media file) for image link targets in block editor.

= 0.12.2 =
- Fixed bug whereby settings were not added to the database for new blogs when the plugin was
already network active.
- Fixed bug whereby settings were not added to the database for new blogs when
the plugin was already network active.
- Added routines to clean up database if ALP is uninstalled.
- Added extra test.
4 changes: 2 additions & 2 deletions ssl-alp/alp.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* Plugin Name: Academic Labbook
* Plugin URI: https://alp.attackllama.com/
* Description: Turn WordPress into a collaborative academic labbook.
* Version: 0.20.2
* Version: 0.21.0
* Author: Sean Leavey
* Author URI: https://attackllama.com/
* License: GPL3
Expand All @@ -21,7 +21,7 @@
* Current plugin version.
*/

define( 'SSL_ALP_VERSION', '0.20.2' );
define( 'SSL_ALP_VERSION', '0.21.0' );

/**
* Plugin name and path
Expand Down
6 changes: 3 additions & 3 deletions ssl-alp/includes/class-ssl-alp-coauthors.php
Original file line number Diff line number Diff line change
Expand Up @@ -111,7 +111,7 @@ public function register_hooks() {
$loader->add_action( 'wp', $this, 'fix_author_query_data', 10, 0 );

// Allow public coauthor query vars.
$loader->add_filter( 'query_vars', $this, 'whitelist_search_query_vars' );
$loader->add_filter( 'query_vars', $this, 'allow_search_query_vars' );

// Support coauthor querystrings in WP_Query.
$loader->add_action( 'parse_tax_query', $this, 'parse_query_vars' );
Expand Down Expand Up @@ -1263,13 +1263,13 @@ public function set_coauthors( $post, $coauthors ) {
}

/**
* Whitelist coauthor query vars.
* Allow coauthor query vars.
*
* This allows coauthored posts to be queried publicly.
*
* @param string[] $public_query_vars Array of public query vars.
*/
public function whitelist_search_query_vars( $public_query_vars ) {
public function allow_search_query_vars( $public_query_vars ) {
global $ssl_alp;

if ( ! get_option( 'ssl_alp_allow_multiple_authors' ) ) {
Expand Down
6 changes: 3 additions & 3 deletions ssl-alp/includes/class-ssl-alp-core.php
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ public function register_admin_styles() {
public function register_scripts() {
if ( get_option( 'ssl_alp_disable_social_media_blocks' ) ) {
wp_register_script(
'ssl-alp-blacklist-blocks',
esc_url( SSL_ALP_BASE_URL . 'js/blacklist-social-media-blocks.js' ),
'ssl-alp-disallow-blocks',
esc_url( SSL_ALP_BASE_URL . 'js/disallow-social-media-blocks.js' ),
array(
'wp-blocks',
'wp-dom-ready',
Expand Down Expand Up @@ -174,7 +174,7 @@ public function enqueue_admin_styles() {
*/
public function enqueue_block_editor_scripts() {
if ( get_option( 'ssl_alp_disable_social_media_blocks' ) ) {
wp_enqueue_script( 'ssl-alp-blacklist-blocks' );
wp_enqueue_script( 'ssl-alp-disallow-blocks' );
}
}

Expand Down
8 changes: 4 additions & 4 deletions ssl-alp/includes/class-ssl-alp-inventory.php
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@ public function register_hooks() {
$loader->add_action( 'added_term_relationship', $this, 'reject_invalid_inventory_terms', 10, 3 );

// Allow public inventory item query vars.
$loader->add_filter( 'query_vars', $this, 'whitelist_search_query_vars' );
$loader->add_filter( 'query_vars', $this, 'allow_search_query_vars' );

// Support inventory item querystrings in WP_Query.
$loader->add_action( 'parse_tax_query', $this, 'parse_query_vars' );
Expand Down Expand Up @@ -181,7 +181,7 @@ public function register_post_type() {
'labels' => $labels,
'description' => __( 'Inventory items.', 'ssl-alp' ),
'public' => true,
'hierarchical' => false,
'hierarchical' => true,
'show_in_rest' => true,
'menu_icon' => 'dashicons-book-alt',
'supports' => array(
Expand Down Expand Up @@ -666,13 +666,13 @@ public function reject_invalid_inventory_terms( $object_id, $tt_id, $taxonomy )
}

/**
* Whitelist inventory item query vars.
* Allow inventory item query vars.
*
* This allows inventory items to be queried publicly.
*
* @param string[] $public_query_vars Array of public query vars.
*/
public function whitelist_search_query_vars( $public_query_vars ) {
public function allow_search_query_vars( $public_query_vars ) {
global $ssl_alp;

if ( ! get_option( 'ssl_alp_enable_inventory' ) ) {
Expand Down
Loading

0 comments on commit 8ea9366

Please sign in to comment.