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 config 'fields' to vk provider #372

Merged
merged 11 commits into from Oct 10, 2018

Conversation

@slaawwa
Copy link
Contributor

slaawwa commented Jul 4, 2018

Update response data from vk (move 'uid' to 'id')
And add custom config 'fields'

const data = await get('https://api.vk.com/method/users.get', query);
const profile = data.response[0];

credentials.profile = {
id: profile.uid,
id: profile.id,

This comment has been minimized.

Copy link
@AdriVanHoudt

AdriVanHoudt Jul 10, 2018

Contributor

Afaik the api returns uid not id?
https://vk.com/dev/fields

This comment has been minimized.

Copy link
@slaawwa

slaawwa Jul 12, 2018

Author Contributor

@AdriVanHoudt, page move from
https://vk.com/dev/fields
to
https://vk.com/dev/objects/user

https://vk.com/dev/users.get

Returns a list of user objects. 

A deactivated field may be returned with the value deleted or banned if a user has been suspended.

I think vk team move field uid to field id in last version

This comment has been minimized.

Copy link
@AdriVanHoudt

AdriVanHoudt Jul 16, 2018

Contributor

I can get to both pages by clicking through the docs so confused haha
Do you use the api? Can you validate that this change works?

This comment has been minimized.

Copy link
@slaawwa

slaawwa Jul 19, 2018

Author Contributor

@AdriVanHoudt, yes. I use it) And this is reason why I create this pull-request)

This comment has been minimized.

Copy link
@slaawwa

slaawwa Jul 19, 2018

Author Contributor

@AdriVanHoudt, maybe try get id field and if it's field not exist try get uid field?
For support old api version

This comment has been minimized.

Copy link
@AdriVanHoudt

AdriVanHoudt Jul 23, 2018

Contributor

Sounds like a plan, if you change that I will merge 🎉

This comment has been minimized.

Copy link
@slaawwa

slaawwa Jul 25, 2018

Author Contributor

@AdriVanHoudt, what the problem with travis tests?
Or everything is ok? Last commit need reject?

@AdriVanHoudt AdriVanHoudt self-assigned this Oct 8, 2018
@AdriVanHoudt AdriVanHoudt added the feature label Oct 8, 2018
@AdriVanHoudt AdriVanHoudt merged commit 58f0d4a into hapijs:master Oct 10, 2018
1 check passed
1 check passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@AdriVanHoudt AdriVanHoudt added this to the 10.0.0 milestone Oct 10, 2018
@hueniverse hueniverse changed the title V9.3.2 add config 'fields' to vk provider Add config 'fields' to vk provider Nov 10, 2018
@hueniverse hueniverse modified the milestones: 10.0.0, 9.3.2 Nov 10, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
3 participants
You can’t perform that action at this time.