preserve existing categories when updating an app from an embed source
This commit is contained in:
parent
d4e91d5d9b
commit
bb4f9eecbe
@ -872,6 +872,12 @@ class Apps {
|
|||||||
dbesc($darray['app_id']),
|
dbesc($darray['app_id']),
|
||||||
intval($darray['app_channel'])
|
intval($darray['app_channel'])
|
||||||
);
|
);
|
||||||
|
|
||||||
|
// if updating an embed app, don't mess with any existing categories.
|
||||||
|
|
||||||
|
if(array_key_exists('embed',$arr) && intval($arr['embed']))
|
||||||
|
return $ret;
|
||||||
|
|
||||||
if($x) {
|
if($x) {
|
||||||
q("delete from term where otype = %d and oid = %d",
|
q("delete from term where otype = %d and oid = %d",
|
||||||
intval(TERM_OBJ_APP),
|
intval(TERM_OBJ_APP),
|
||||||
|
Reference in New Issue
Block a user