Restore unified paid download model
This commit is contained in:
@@ -476,6 +476,9 @@ add_filter('single_template', function ($template) {
|
||||
if (!($post instanceof WP_Post)) return $template;
|
||||
if (!function_exists('aksrt_is_resource_post')) return $template;
|
||||
if (!aksrt_is_resource_post($post)) return $template;
|
||||
if (function_exists('aksrt_is_downloadable_content') && !aksrt_is_downloadable_content($post)) {
|
||||
return $template;
|
||||
}
|
||||
$candidate = locate_template(['single-aksrt_resource.php']);
|
||||
return $candidate ?: $template;
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user