]> git.mxchange.org Git - friendica.git/commitdiff
Avoid a Notice
authorTobias Hößl <tobias@hoessl.eu>
Mon, 27 Feb 2012 22:08:00 +0000 (22:08 +0000)
committerTobias Hößl <tobias@hoessl.eu>
Mon, 27 Feb 2012 22:08:00 +0000 (22:08 +0000)
include/items.php

index 7d52571c25d6a176d32a0b70540df807102ac2ed..5452dfbdab93c1e2313b3bf67e5ad3325714f438 100755 (executable)
@@ -682,7 +682,7 @@ function item_store($arr,$force_parent = false) {
                unset($arr['dsprsig']);
        }
 
-       if($arr['gravity'])
+       if(x($arr, 'gravity'))
                $arr['gravity'] = intval($arr['gravity']);
        elseif($arr['parent-uri'] === $arr['uri'])
                $arr['gravity'] = 0;
@@ -800,6 +800,8 @@ function item_store($arr,$force_parent = false) {
                                logger('item_store: item parent was not found - ignoring item');
                                return 0;
                        }
+                       
+                       $parent_deleted = 0;
                }
        }