Title: Code Change Suggestion
Last modified: May 18, 2023

---

# Code Change Suggestion

 *  Resolved [emar5x5](https://wordpress.org/support/users/emar5x5/)
 * (@emar5x5)
 * [3 years ago](https://wordpress.org/support/topic/code-change-suggestion/)
 * Hi there,
   I’ve got a bit of a suggestion that I would like to give. Recently 
   I encountered an issue with WP Ultimate CSV Importer. I’m logged in as an administrator
   but I can’t access the importer and an error message would show that says “Sorry,
   you are not allowed to access this page”. After checking the plugin code I found
   out that it checks whether the user is logged in and its role in index 0 is administrator.
   Upon checking with my admin roles; the user role did not start on 0 rather it
   started on index 12 [https://prnt.sc/tXcXZ8jCpO1W](https://prnt.sc/tXcXZ8jCpO1W).
   My suggestion is that, on line 109 and 493 of file wp-ultimate-csv-importer.php,
   instead of using this line;_if(!empty($role) && !empty($role[0]==’administrator’)){
   _can you change it to like this below ?_if(!empty($role) && !empty( in\_array(‘
   administrator’ , $role ) )){_Cheers
    -  This topic was modified 3 years ago by [emar5x5](https://wordpress.org/support/users/emar5x5/).

Viewing 1 replies (of 1 total)

 *  [smacksupport](https://wordpress.org/support/users/smacksupport/)
 * (@smacksupport)
 * [3 years ago](https://wordpress.org/support/topic/code-change-suggestion/#post-16753408)
 * Hi [@emar5x5](https://wordpress.org/support/users/emar5x5/) , we have fixed this
   in the upcoming version and will release it soon. Thank you for your valuable
   comment.

Viewing 1 replies (of 1 total)

The topic ‘Code Change Suggestion’ is closed to new replies.

 * ![](https://ps.w.org/wp-ultimate-csv-importer/assets/icon.svg?rev=3131703)
 * [WP Ultimate CSV Importer – WordPress Import & Export for CSV, XML & Excel](https://wordpress.org/plugins/wp-ultimate-csv-importer/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/wp-ultimate-csv-importer/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/wp-ultimate-csv-importer/)
 * [Active Topics](https://wordpress.org/support/plugin/wp-ultimate-csv-importer/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/wp-ultimate-csv-importer/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/wp-ultimate-csv-importer/reviews/)

 * 1 reply
 * 2 participants
 * Last reply from: [smacksupport](https://wordpress.org/support/users/smacksupport/)
 * Last activity: [3 years ago](https://wordpress.org/support/topic/code-change-suggestion/#post-16753408)
 * Status: resolved