git.ithinksw.org
/
philo.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Split shipherd NodeNavigationInline into inlines for hosted/targeting inlines. Added...
[philo.git]
/
contrib
/
shipherd
/
models.py
diff --git
a/contrib/shipherd/models.py
b/contrib/shipherd/models.py
index
2577245
..
0643c3e
100644
(file)
--- a/
contrib/shipherd/models.py
+++ b/
contrib/shipherd/models.py
@@
-71,11
+71,11
@@
class NavigationManager(TreeManager):
return hosted_navigation
def _add_to_cache(self, using, node, qs=None):
return hosted_navigation
def _add_to_cache(self, using, node, qs=None):
- if node.pk is None:
- return
-
if qs is None:
if qs is None:
- roots = node.hosted_navigation.select_related('target_node')
+ try:
+ roots = node.hosted_navigation.select_related('target_node')
+ except AttributeError:
+ roots = []
qs = self.none()
for root in roots:
qs = self.none()
for root in roots: