Problem with "Depreciated in 1.7: get_entity() Error. Help please

When selecting the GROUP page on my site here I get the above error.

Depreciated in 1.7: get_entity() was depreciated by elgg_get_entities().

I can't find out if this is an outdated module causing this or what.

Any pointers as how to resolve ?

 

  • grep for 'get_entity('  in the whole elgg directory...

  • Alternatively, start by disabling 3rd party plugins. If the error is gone, you know which plugin is causing the issue and searching for the get_entity line might be easier.

  • @Andy1966uk

    In order to quickly find where this depreciated call is located, you should use Elgg Developer Tools plugin. Activate this plugin and do the following:

    1) Turn off Use simple cache (just for now).
    2) set Trace level to Warnings.
    3) Activate/check Log to the screen.
    4) Go to http://www.iracebook.net/groups/profile/42/formula-1

    You will see on the page bottom the warning that indicate exactly where this call loctaed
    (Something like: WARNING: Deprecated in 1.8: ........... )

    A great plugin for developers by the way :-)

     

     

     

  • Peter M

    ok, y'all that's called "software developers.." ;-)
    ..this is not called "rocket science" ;-)
    it's about as easy as eating american pie....
    just goto the elgg lib code for deprecated
    and in the function, at the top add :=>

    function ..... {

        if (elgg_is_admin_logged_in()) { // no deprecated notice unless Admin is logged in ;-oP 
            return TRUE;
        }
    . . .  etc

    any volunteers for a pull request to "fix" ?

  • whatever plugin u are running that is causing this issue go into its start.php and search for get_entities and everywhere in the code change it to elgg_get_entities this will take the errors away, u also have to replace list_entities with elgg_list_entities and Extend_view with elgg_extend_view this will take all visible errors away

  • i see small typo above ;-)
    shud be
    if ( ! elgg_is_admin_logged_in..

     

  • Well, this issue would be irrelevant if you would have your development environment (and maybe also a test environment, if you can afford it) separated form production development :-)  That is what I always do.

    Otherwise, this needs to be fixed anyway - warnings for admins only!