Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add method Wikimate::logout() #124

Merged
merged 2 commits into from
Aug 25, 2021
Merged

Add method Wikimate::logout() #124

merged 2 commits into from
Aug 25, 2021

Conversation

Xymph
Copy link
Collaborator

@Xymph Xymph commented Aug 25, 2021

Covers the API action Logout and discards CSRF token (per #115).

The error code value is 'auth' because it doesn't make much sense to define a code 'logout' that's unlikely ever checked. Instead it would be logical to change the 'login' code into 'auth' as well (possibly also useful for #87 and #89), but that would be an small API-breaking change (similar to #116), so has to be delayed til v1.0.0. Hence the 'auth' entry is added to USAGE.md but the 'login' entry not yet removed.

A logout() example in USAGE.md would be too trivial so I didn't bother.
USAGE.md also includes a user agent fix I missed in #121.

@Xymph Xymph mentioned this pull request Aug 25, 2021
@Xymph Xymph requested a review from waldyrious August 25, 2021 13:18
Copy link
Collaborator

@waldyrious waldyrious left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left a couple suggestions inline for the documentation. The code itself LGTM.

Wikimate.php Show resolved Hide resolved
USAGE.md Show resolved Hide resolved
Copy link
Collaborator

@waldyrious waldyrious left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@waldyrious waldyrious merged commit 19d181c into hamstar:master Aug 25, 2021
@Xymph Xymph deleted the 124-logout branch August 25, 2021 15:24
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.

2 participants