Implemented iter_revisions. Various minor fixes.
The methode iter_revisions(page) is now implemented, and yiels the last ten revisions of the page, as 'Revision' objects. Various fixes, like removing unused imports.
This commit is contained in:
parent
200ab648bb
commit
5d24cec733
2 changed files with 33 additions and 7 deletions
|
|
@ -50,8 +50,9 @@ class MediawikiBackend(BaseBackend, ICapContent):
|
|||
content.content = data
|
||||
return content
|
||||
|
||||
def log_content(self, id):
|
||||
raise NotImplementedError()
|
||||
def iter_revisions(self, _id):
|
||||
for rev in self.browser.iter_wiki_revisions(_id):
|
||||
yield rev
|
||||
|
||||
|
||||
def push_content(self, content, message=None, minor=False):
|
||||
|
|
@ -59,6 +60,3 @@ class MediawikiBackend(BaseBackend, ICapContent):
|
|||
|
||||
def get_content_preview(self, content):
|
||||
return self.browser.get_wiki_preview(content)
|
||||
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue