Unable to Import Users: undefined function get_current_screen()

While importing a list of users, my client was getting an error. When I looked at the logs, I found the following error:

PHP Fatal error: Call to undefined function get_current_screen() in …/wp-content/plugins/groups/lib/admin/class-groups-admin-user-profile.php on line 106, referer: …/wp-admin/admin.php?page=groups-user-import

I added the following line in this file, which resolved the issue for us:

require_once(ABSPATH . ‘wp-admin/includes/screen.php’);

But, I expect my change will get blown away the next time you update this plugin.

One Response to Unable to Import Users: undefined function get_current_screen()

  1. antonio April 26, 2017 at 5:35 pm #

    Hi Jane,
    Thank you very much for the contribution.
    Really I can not replicate this issue, if you can , please give me the versions that you are using and if you are using another plugins related to the users registration.
    Thanks,
    Antonio B.

We use cookies to optimize your experience on our site and assume you're OK with that if you stay.
OK, hide this message.

Affiliates · Contact · Jobs · Terms & Conditions · Privacy Policy · Documentation · Downloads · Useful Plugins · My Account

Share