fix: calc shortcode name mismatch — prc_calculator not peptide_tools_calculator (v2.1.3)
page-calculator.php and module-cards.php were both checking for 'peptide_tools_calculator' which the plugin never registered. The calc plugin (prc) registers 'prc_calculator' — template fell through to the 'currently being set up' fallback on every request.
This commit is contained in:
@@ -33,8 +33,8 @@ get_header();
|
|||||||
<section class="ps-tool-page">
|
<section class="ps-tool-page">
|
||||||
<div class="ps-container">
|
<div class="ps-container">
|
||||||
<?php
|
<?php
|
||||||
if ( shortcode_exists( 'peptide_tools_calculator' ) ) {
|
if ( shortcode_exists( 'prc_calculator' ) ) {
|
||||||
echo do_shortcode( '[peptide_tools_calculator]' );
|
echo do_shortcode( '[prc_calculator]' );
|
||||||
} else {
|
} else {
|
||||||
?>
|
?>
|
||||||
<div class="ps-tool-fallback">
|
<div class="ps-tool-fallback">
|
||||||
|
|||||||
@@ -4,7 +4,7 @@ Theme URI: https://github.com/peptiderepo/peptide-starter
|
|||||||
Description: Premium, accessible WordPress theme for scientific peptide reference database
|
Description: Premium, accessible WordPress theme for scientific peptide reference database
|
||||||
Author: Peptide Repo
|
Author: Peptide Repo
|
||||||
Author URI: https://peptiderepo.com
|
Author URI: https://peptiderepo.com
|
||||||
Version: 2.1.2
|
Version: 2.1.3
|
||||||
License: GPL v2 or later
|
License: GPL v2 or later
|
||||||
License URI: https://www.gnu.org/licenses/gpl-2.0.html
|
License URI: https://www.gnu.org/licenses/gpl-2.0.html
|
||||||
Text Domain: peptide-starter
|
Text Domain: peptide-starter
|
||||||
|
|||||||
@@ -34,7 +34,7 @@ $modules = array(
|
|||||||
'description' => __( 'Reconstitute a peptide accurately. Enter the vial, the bacteriostatic water, the target dose; get the units.', 'peptide-starter' ),
|
'description' => __( 'Reconstitute a peptide accurately. Enter the vial, the bacteriostatic water, the target dose; get the units.', 'peptide-starter' ),
|
||||||
'url' => '/calculator',
|
'url' => '/calculator',
|
||||||
'icon' => '<svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect x="4" y="2" width="16" height="20" rx="2"/><line x1="8" y1="6" x2="16" y2="6"/><line x1="8" y1="10" x2="10" y2="10"/><line x1="14" y1="10" x2="16" y2="10"/><line x1="8" y1="14" x2="10" y2="14"/><line x1="14" y1="14" x2="16" y2="14"/><line x1="8" y1="18" x2="16" y2="18"/></svg>',
|
'icon' => '<svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect x="4" y="2" width="16" height="20" rx="2"/><line x1="8" y1="6" x2="16" y2="6"/><line x1="8" y1="10" x2="10" y2="10"/><line x1="14" y1="10" x2="16" y2="10"/><line x1="8" y1="14" x2="10" y2="14"/><line x1="14" y1="14" x2="16" y2="14"/><line x1="8" y1="18" x2="16" y2="18"/></svg>',
|
||||||
'available' => shortcode_exists( 'peptide_tools_calculator' ),
|
'available' => shortcode_exists( 'prc_calculator' ),
|
||||||
),
|
),
|
||||||
array(
|
array(
|
||||||
'title' => __( 'Protocol Builder', 'peptide-starter' ),
|
'title' => __( 'Protocol Builder', 'peptide-starter' ),
|
||||||
|
|||||||
Reference in New Issue
Block a user