~loggerhead-team/loggerhead/trunk-rich

« back to all changes in this revision

Viewing changes to loggerhead/controllers/atom_ui.py

[bug=758618] Remove the HeadMiddleware in 'bzr serve --http',
until it can be fixed properly.

Show diffs side-by-side

added added

removed removed

Lines of Context:
24
24
 
25
25
    template_path = 'loggerhead.templates.atom'
26
26
 
27
 
    def get_values(self, h, args, kw, headers):
 
27
    def get_values(self, path, kwargs, headers):
 
28
        history = self._history
28
29
        pagesize = int(20)#self._branch.config.get('pagesize', '20'))
29
30
 
30
 
        revid_list = h.get_file_view(h.last_revid, None)
31
 
        entries = list(h.get_changes(list(revid_list)[:pagesize]))
 
31
        revid_list = history.get_file_view(history.last_revid, None)
 
32
        entries = list(history.get_changes(list(revid_list)[:pagesize]))
32
33
 
33
34
        headers['Content-Type'] = 'application/atom+xml'
34
35
        return {
35
36
            'changes': entries,
36
 
            'updated': entries[0].date.isoformat() + 'Z',
 
37
            'updated': entries[0].utc_date.isoformat(),
 
38
            'history': self._history,
37
39
        }