commit 3f975f8329870f0dcda259b87d404c8843ed6d1c
parent 6c838c5bc9354587e100346f165e6172d31c38d4
Author: MTRNord <mtrnord1@gmail.com>
Date: Sat, 31 Mar 2018 21:15:08 +0200
Finish callbackFunction
Diffstat:
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/src/app/callback/twitter/twitter.component.ts b/src/app/callback/twitter/twitter.component.ts
@@ -21,8 +21,8 @@ import {DOCUMENT} from '@angular/common';
})
export class TwitterComponent implements OnInit {
url: string;
- accessToken: string;
- accessSecret: string;
+ oauth_token: string;
+ oauth_verifier: string;
constructor(private toastr: ToastrService, private route: ActivatedRoute, @Inject(DOCUMENT) private document, private http: HttpClient) {
this.url = document.location.protocol + '//' + document.location.hostname + '/api';
@@ -34,10 +34,10 @@ export class TwitterComponent implements OnInit {
.subscribe(params => {
console.log(params);
- this.accessToken = params.accessToken;
- this.accessSecret = params.accessSecret;
+ this.oauth_token = params.oauth_token;
+ this.oauth_verifier = params.oauth_verifier;
- this.http.get(`${this.url}/login/twitter/callback`)
+ this.http.get(`${this.url}/login/twitter/callback?oauth_token=${this.oauth_token}&oauth_verifier=${this.oauth_verifier}`)
// TODO: Better variable naming
.retryWhen(oerror => {
return oerror