cwconfig.py
changeset 5545 25fd74c23f91
parent 5473 ee87c5352e63
parent 5534 b75aa6ce0c04
child 5633 879590c52679
--- a/cwconfig.py	Mon May 17 11:05:37 2010 +0200
+++ b/cwconfig.py	Tue May 18 18:18:08 2010 +0200
@@ -955,7 +955,10 @@
 
     def load_site_cubicweb(self):
         """load instance's specific site_cubicweb file"""
-        for path in reversed([self.apphome] + self.cubes_path()):
+        paths = self.cubes_path()
+        if self.apphome is not None:
+            paths = [self.apphome] + paths
+        for path in reversed(paths):
             sitefile = join(path, 'site_cubicweb.py')
             if exists(sitefile) and not sitefile in self._site_loaded:
                 self._load_site_cubicweb(sitefile)