Creating common token store and moving email invites and verification to it (#6213)

Этот коммит содержится в:
Christopher Speller
2017-04-27 10:55:03 -04:00
коммит произвёл Joram Wilander
родитель 0e007e344b
Коммит 9a87bb3af6
30 изменённых файлов: 461 добавлений и 461 удалений

Просмотреть файл

@@ -1319,19 +1319,19 @@ export default class Client {
this.trackEvent('api', 'api_channels_set_active', {channel_id: id});
}
verifyEmail(uid, hid, success, error) {
verifyEmail(token, success, error) {
request.
post(`${this.getUsersRoute()}/verify_email`).
post(`${this.url}/api/v4/users/email/verify`).
set(this.defaultHeaders).
type('application/json').
accept('application/json').
send({uid, hid}).
send({token}).
end(this.handleResponse.bind(this, 'verifyEmail', success, error));
}
resendVerification(email, success, error) {
request.
post(`${this.getUsersRoute()}/resend_verification`).
post(`${this.url}/api/v4/users/email/verify/send`).
set(this.defaultHeaders).
type('application/json').
accept('application/json').