Call to undefined function wp_get_current_user() in capabilities.php

I had a website which wasn’t updated for a long time. Suddenly, few days ago, my website stopped working and found this error line in error_log file.

[18-Mar-2014 19:16:43 UTC] PHP Fatal error:  Call to undefined function wp_get_current_user() in /home8/****/public_html/wp-includes/capabilities.php on line 1289

I have tried everything I know and almost every claims found online. What could be the possible reason and solution for this outage?

Related posts

Leave a Reply

2 comments

  1. Solution is include the pluggable file in your plguin file. After include this file easily resolve your problem.
    require_once( ABSPATH . ‘/wp-includes/pluggable.php’ );
    $user_info = wp_get_current_user();