Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue with ELGG - Files - Friends' Files - subtype menu (Trac #2641) #2641

Closed
elgg-gitbot opened this issue Feb 16, 2013 · 4 comments
Closed
Labels
Milestone

Comments

@elgg-gitbot
Copy link

Original ticket http://trac.elgg.org/ticket/2641 on 40862722-07-10 by trac user kienvu, assigned to cash.

Elgg version: 1.7

We experienced a issue with ELGG - Files - Friends' Files - subtype menu:


These are steps to re-produce it.

Logged into ELGG

Go to Tools - Files

Go to Your Friends' Files - http://ELGGSITE/pg/file/acarer/friends/
Files show up

Click on All - http://ELGGSITE/mod/file/search.php?subtype=file&md_type=simpletype&tag=video&friends_guid=8532&page_owner=8532

NOTHING shows up


I have looked at the core code and regconize the error from function elgg_normalise_plural_options_array($options, $singulars) in /engine/lib/elgglib.php

The reason is: the function elgg_get_entities() has problem if the owner_guid is an array of array( this is caused by the elgg_normalise_plural_options_array() function.


To fix this we change the code in function elgg_normalise_plural_options_array($options, $singulars) in /engine/lib/elgglib.php

Need to change the old code from :

$options[$plural] = array($options[$singular]);

To

if(!is_array($options[$singular])) $options[$plural] = array($options[$singular]);
else $options[$plural] = $options[$singular];

@elgg-gitbot
Copy link
Author

cash wrote on 40862786-08-29

Confirmed. Thanks for looking into this!

@elgg-gitbot
Copy link
Author

Milestone changed to Elgg 1.7.5 by cash on 40862786-08-29

@elgg-gitbot
Copy link
Author

cash wrote on 40862788-10-01

(In [svn:7295]) Fixes #2641 was not checking for arrays in singular test

@elgg-gitbot
Copy link
Author

cash wrote on 40862793-04-25

(In [svn:7296]) Refs #2641 merged [svn:7295] into trunk

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

No branches or pull requests

1 participant