Skip to content

Readme improvements, adding pages#3

Open
Efreak wants to merge 4 commits intooliver-moran:masterfrom
Efreak:master
Open

Readme improvements, adding pages#3
Efreak wants to merge 4 commits intooliver-moran:masterfrom
Efreak:master

Conversation

@Efreak
Copy link
Copy Markdown

@Efreak Efreak commented Sep 24, 2014

Fixed some references in the example code to make it usable by copy/paste, added syntax highlighting, and made the browser example a clickable link.

Wikimedia is the organization. MediaWiki is the software. Regardless of what it's called, the initial `require` calls it MediaWiki, so call it that elsewhere as well, so copy/paste testing works
If page does not exist, there won't be any revisions to get a timestamp from. Only grab/use basetimestamp if there are revisions; if there aren't any, then tell mediawiki to only create a page, not edit an existing one (you're going to the trouble with timestamps, so why not?)
@Efreak
Copy link
Copy Markdown
Author

Efreak commented Sep 24, 2014

I added some code to fix the issue I had with creating new pages. You were looking for a timestamp in the first revision of the page, but there are no revisions on a new page, so creating a new page caused an error TypeError: Cannot read property '0' of undefined

@Efreak Efreak changed the title Readme improvements Readme improvements, adidng pages Oct 1, 2014
@Efreak Efreak changed the title Readme improvements, adidng pages Readme improvements, adding pages Oct 1, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant