Switch to unified view

a/Allura/allura/controllers/auth.py b/Allura/allura/controllers/auth.py
...
...
293
        projects = dict(
293
        projects = dict(
294
            (p._id, p) for p in project_collection.m.find(dict(
294
            (p._id, p) for p in project_collection.m.find(dict(
295
                    _id={'$in': [mb.project_id for mb in mailboxes ]})))
295
                    _id={'$in': [mb.project_id for mb in mailboxes ]})))
296
        app_index = dict(
296
        app_index = dict(
297
            (ac._id, ac) for ac in app_collection.m.find(dict(
297
            (ac._id, ac) for ac in app_collection.m.find(dict(
298
                    _id={'$in': [mb.project_id for mb in mailboxes]})))
298
                    _id={'$in': [mb.app_config_id for mb in mailboxes]})))
299
299
300
        for mb in mailboxes:
300
        for mb in mailboxes:
301
            project = projects.get(mb.project_id, None)
301
            project = projects.get(mb.project_id, None)
302
            app_config = app_index.get(mb.app_config_id, None)
302
            app_config = app_index.get(mb.app_config_id, None)
303
            if project is None:
303
            if project is None:
...
...
309
            if mb.artifact_url:
309
            if mb.artifact_url:
310
                title = '<a href="%s">%s</a>' % (mb.artifact_url,title)
310
                title = '<a href="%s">%s</a>' % (mb.artifact_url,title)
311
            subscriptions.append(dict(
311
            subscriptions.append(dict(
312
                    _id=mb._id,
312
                    _id=mb._id,
313
                    project_name=project.name,
313
                    project_name=project.name,
314
                    mount_point=app_config.options.mount_point,
314
                    mount_point=app_config.options['mount_point'],
315
                    artifact_title=title,
315
                    artifact_title=title,
316
                    topic=mb.topic,
316
                    topic=mb.topic,
317
                    type=mb.type,
317
                    type=mb.type,
318
                    frequency=mb.frequency.unit,
318
                    frequency=mb.frequency.unit,
319
                    artifact=mb.artifact_index_id))
319
                    artifact=mb.artifact_index_id))