Plugin Directory

Changeset 3442103


Ignore:
Timestamp:
01/18/2026 08:54:04 PM (2 months ago)
Author:
whiteshadow
Message:

Fix fatal error caused by trying to enqueue a Pro version script in the Redirects tab in the free version.

Oops, the dependency collection helper didn't distinguish between the free and Pro version. The free version only has the basic KO extensions script.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • admin-menu-editor/trunk/includes/module.php

    r3434530 r3442103  
    335335
    336336    public function koExtensions(): self {
    337         $this->add('ame-ko-extensions');
    338         //Note: We don't need to explicitly include "ame-knockout" or "ame-free-ko-extensions" since
    339         //"ame-ko-extensions" already has those as a dependencies.
     337        if ( !empty($this->deps['ame-ko-extensions']) ) {
     338            $this->add('ame-ko-extensions');
     339            //Note: We don't need to explicitly include "ame-knockout" or "ame-free-ko-extensions" since
     340            //"ame-ko-extensions" already has those as a dependencies.
     341        } else {
     342            //Fallback for the free version.
     343            $this->add('ame-free-ko-extensions');
     344        }
    340345        return $this;
    341346    }
Note: See TracChangeset for help on using the changeset viewer.