Admin Media Page Error: Function wpdb::prepare was called incorrectly

[ad_1]

After installing the Folders plugin version 2.9.2 in a fresh WordPress 6.2 instance, navigation to the admin media page results in the following error:

ErrorException(E_USER_NOTICE)

Function wpdb::prepare was called <strong>incorrectly</strong>. The query argument of wpdb::prepare() must have a placeholder. Please see <a href=”https://projectdmc.org/documentation/article/debugging-in-wordpress/”>Debugging in WordPress</a> for more information. (This message was added in version 3.9.0.)

ErrorException

…/htdocs/cms/wp-includes/functions.php5858

8

trigger_error

…/htdocs/cms/wp-includes/functions.php5858

7

_doing_it_wrong

…/htdocs/cms/wp-includes/class-wpdb.php1502

6

wpdbprepare

…/htdocs/content/plugins/folders/includes/folders.class.php1761

5

WCP_Foldersget_tempt_posts

…/htdocs/content/plugins/folders/includes/folders.class.php4374

4

WCP_Foldersadmin_footer

…/htdocs/cms/wp-includes/class-wp-hook.php308

3

WP_Hookapply_filters

…/htdocs/cms/wp-includes/class-wp-hook.php332

2

WP_Hookdo_action

…/htdocs/cms/wp-includes/plugin.php517

1

do_action

…/htdocs/cms/wp-admin/admin-footer.php78

0

require_once

…/htdocs/cms/wp-admin/upload.php199

I could track it down to
$query = $wpdb->prepare($query, $taxonomy, $post_type);
in
/plugins/folders/includes/folders.class.php:1760

Commenting this line removes the error and does not seem to have side effects.

 

This site will teach you how to build a WordPress website for beginners. We will cover everything from installing WordPress to adding pages, posts, and images to your site. You will learn how to customize your site with themes and plugins, as well as how to market your site online.

Buy WordPress Transfer