Title: Plugin causing Fatal Error
Last modified: August 21, 2016

---

# Plugin causing Fatal Error

 *  Resolved [neverforget98](https://wordpress.org/support/users/neverforget98/)
 * (@neverforget98)
 * [13 years ago](https://wordpress.org/support/topic/plugin-causing-fatal-error/)
 * This plugin (WP User Avatar) is causing this error on the front-end of my site:
 * Fatal error: Call to undefined function get_current_screen() in /home/devpen/
   public_html/wp-content/themes/pitch/extras/settings/settings.php on line 397
 * Please help. I will be disabling it until someone can help me find a solution.
 * [http://wordpress.org/extend/plugins/wp-user-avatar/](http://wordpress.org/extend/plugins/wp-user-avatar/)

Viewing 4 replies - 1 through 4 (of 4 total)

 *  [Bangbay Siboliban](https://wordpress.org/support/users/bangbay/)
 * (@bangbay)
 * [13 years ago](https://wordpress.org/support/topic/plugin-causing-fatal-error/#post-3780364)
 * It seems to be a problem with the get_current_screen() function in your theme.
   After searching around, a quick fix seems to be to add this:
 *     ```
       function get_current_screen(){
         global $current_screen;
         if(!isset($current_screen)){
           return null;
         }
         return $current_screen;
       }
       ```
   
 * at the bottom of the functions.php file in your Pitch theme folder.
 *  [Bangbay Siboliban](https://wordpress.org/support/users/bangbay/)
 * (@bangbay)
 * [13 years ago](https://wordpress.org/support/topic/plugin-causing-fatal-error/#post-3780504)
 * After looking into it more, adding that function might cause a “Cannot redeclare
   get_current_screen()” error. I’ll have to look into this problem a little further.
 *  [Bangbay Siboliban](https://wordpress.org/support/users/bangbay/)
 * (@bangbay)
 * [13 years ago](https://wordpress.org/support/topic/plugin-causing-fatal-error/#post-3780534)
 * I’ve included a fix for the get_current_screen function within the plugin. Please
   try version 1.4.2 and see if it works for you.
 *  Thread Starter [neverforget98](https://wordpress.org/support/users/neverforget98/)
 * (@neverforget98)
 * [13 years ago](https://wordpress.org/support/topic/plugin-causing-fatal-error/#post-3780535)
 * It worked! That’s awesome! Thank you so much! 🙂
 * Brandin

Viewing 4 replies - 1 through 4 (of 4 total)

The topic ‘Plugin causing Fatal Error’ is closed to new replies.

 * ![](https://ps.w.org/wp-user-avatar/assets/icon-256x256.png?rev=2532486)
 * [Paid Membership Plugin, Ecommerce, User Registration Form, Login Form, User Profile & Restrict Content – ProfilePress](https://wordpress.org/plugins/wp-user-avatar/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-user-avatar/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-user-avatar/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-user-avatar/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-user-avatar/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-user-avatar/reviews/)

 * 4 replies
 * 2 participants
 * Last reply from: [neverforget98](https://wordpress.org/support/users/neverforget98/)
 * Last activity: [13 years ago](https://wordpress.org/support/topic/plugin-causing-fatal-error/#post-3780535)
 * Status: resolved