If updertEntry is called with an array structure, make sure it is usable
This commit is contained in:
parent
8d0b1b79be
commit
38c19fc150
@ -1367,6 +1367,8 @@ function serendipity_updertEntry($entry) {
|
||||
foreach ($categories as $cat) {
|
||||
if (is_numeric($cat)) {
|
||||
serendipity_db_query("INSERT INTO {$serendipity['dbPrefix']}entrycat (entryid, categoryid) VALUES ({$entry['id']}, {$cat})");
|
||||
} elseif (is_array($cat) && !empty($cat['categoryid'])) {
|
||||
serendipity_db_query("INSERT INTO {$serendipity['dbPrefix']}entrycat (entryid, categoryid) VALUES ({$entry['id']}, {$cat['categoryid']})");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user