[WP Smush Pro] Fatal error with WP Smush Pro 2.7.9

Latest update gives the following fatal error on the front-end:

Fatal error: Uncaught Error: Call to undefined function get_current_screen() in /nas/content/live/pwppaula/wp-content/plugins/wp-smush-pro/lib/class-wp-smush-admin.php:341 Stack trace: #0 [internal function]: WpSmushitAdmin->enqueue('':wink: #1 /nas/content/live/pwppaula/wp-includes/class-wp-hook.php(286): call_user_func_array(Array, Array) #2 /nas/content/live/pwppaula/wp-includes/class-wp-hook.php(310): WP_Hook->apply_filters('', Array) #3 /nas/content/live/pwppaula/wp-includes/plugin.php(453): WP_Hook->do_action(Array) #4 /nas/content/live/pwppaula/wp-includes/media.php(3663): do_action('wp_enqueue_medi...':wink: #5 /nas/content/live/pwppaula/wp-content/themes/flatads/functions.php(251): wp_enqueue_media() #6 [internal function]: wpcook_add_media_upload_scripts('':wink: #7 /nas/content/live/pwppaula/wp-includes/class-wp-hook.php(286): call_user_func_array('wpcook_add_medi...', Array) #8 /nas/content/live/pwppaula/wp-includes/class-wp-hook.php(310): WP_Hook->apply_filters(NULL, Array) #9 /nas/content/live/pwppaula/wp-includes/plugin.p in /nas/content/live/pwppaula/wp-content/plugins/wp-smush-pro/lib/class-wp-smush-admin.php on line 341

The wp_enqueue_media() function is called in the front-end, because there is an image upload process for users. The previous version of Smush Pro was working with the same code.

I see in the changelog, that you removed all functions from front-end and I believe this is the problem. Maybe a checkbox should be added for those, who still want to load Smush Pro on the front-end.

The plugin is deactivated now, because the website would not load.