WordPress.org

Forums

Role Scoper
[resolved] Warning: Call-time pass-by-reference has been deprecated; (4 posts)

  1. xdreamwalker
    Member
    Posted 4 years ago #

    I have been getting this error with the last Role Scoper update.

    Warning: Call-time pass-by-reference has been deprecated; If you would like to pass it by reference, modify the declaration of [runtime function name](). If you would like to enable call-time pass-by-reference, you can set allow_call_time_pass_reference to true in your INI file in /**/wp-content/plugins/role-scoper/defaults_rs.php on line 518

    I have not updated to WP 3.0 yet as I wanted to wait out for bugs and what not. The odd thing is that defaults_rs.php line 518 is blank.

    This error prevents people from logging in.

    http://wordpress.org/extend/plugins/role-scoper/

  2. xdreamwalker
    Member
    Posted 4 years ago #

    Doing some more trial and error this is the code that is throwing the error:

    if ( $include_custom_types && awp_ver( '2.9' ) ) {
    scoper_add_custom_taxonomies(&$arr);
    //add_action( 'init', 'scoper_add_custom_taxonomies', 99 );		// for compat with More Types plugin
    }

    Once I comment out these lines the error goes away and I'm able to log in, and all seems to be working alright. A restricted user only sees what they are supposed to see.

    For some more background; This install is hosted with Go Daddy using PHP 5.2.5

  3. Kevin Behrens
    Member
    Plugin Author

    Posted 4 years ago #

    Thanks for letting me know. The problem is the ampersand in scoper_add_custom_taxonomies(&$arr). Remove it to stop the error. I am!

    FYI, this only prevented login because your server is configured to display PHP warnings onscreen. This is usually due to WP_DEBUG being defined true in wp-config.php, but could be due to a php.ini setting. In the typical WP installation, this would go unnoticed.

  4. xdreamwalker
    Member
    Posted 4 years ago #

    Thank you!

    I have no idea why this works, or how, but deleting the ampersand has resolved this issue.

Topic Closed

This topic has been closed to new replies.

About this Plugin

  • Role Scoper
  • Frequently Asked Questions
  • Support Threads
  • Reviews

About this Topic