repatched includes/entity.inc

This commit is contained in:
Bachir Soussi Chiadmi 2013-09-24 09:13:51 +02:00
parent e539e701f8
commit 32e4448773
2 changed files with 1372 additions and 0 deletions

12
includes/entity.inc Executable file → Normal file
View File

@ -154,6 +154,18 @@ class DrupalDefaultEntityController implements DrupalEntityControllerInterface {
*/
public function load($ids = array(), $conditions = array()) {
$entities = array();
# PATCH http://drupal.org/node/1003788#comment-5195682
// Clean the $ids array to remove non-integer values that can be passed
// in from various sources, including menu callbacks.
if (is_array($ids)) {
foreach ($ids as $key => $id) {
if (empty($id) || ((string) $id !== (string) (int) $id)) {
unset($ids[$key]);
}
}
}
# endpatch
// Revisions are not statically cached, and require a different query to
// other conditions, so separate the revision id into its own variable.

1360
includes/entity.inc.orig Executable file

File diff suppressed because it is too large Load Diff