(self)
return extra_dbs
Create a mapping from database prefix to database url
Create a mapping from database prefix to database url
Create a mapping from database prefix to database url
def get_extra_couchdbs(self):
        """
        Create a mapping from database prefix to database url

        """
        extra_dbs = {}
        postfixes = []
        for row in self.couchdb_apps:
            if isinstance(row, tuple):
                _, postfix = row
                if postfix:
                    postfixes.append(postfix)

        postfixes.extend(self.extra_db_names)
        for postfix in postfixes:
            if postfix in self.db_urls_by_prefix:
                url = self.db_urls_by_prefix[postfix]
            else:
                url = '%s__%s' % (self.main_db_url, postfix)
            extra_dbs[postfix] = url

        return extra_dbs
def get_extra_couchdbs ( self ) : extra_dbs = { } postfixes = [ ] for row in self . couchdb_apps : if isinstance ( row , tuple ) : _ , postfix = row if postfix : postfixes . append ( postfix ) postfixes . extend ( self . extra_db_names ) for postfix in postfixes : if postfix in self . db_urls_by_prefix : url = self . db_urls_by_prefix [ postfix ] else : url = '%s__%s' % ( self . main_db_url , postfix ) extra_dbs [ postfix ] = url return extra_dbs