forked from cory/tildefriends
Fix Strava account linking.
git-svn-id: https://www.unprompted.com/svn/projects/tildefriends/trunk@4436 ed5197a5-7fde-0310-b194-c3ffbd925b24
This commit is contained in:
parent
df9d9425ec
commit
d9c4d847a1
@ -1,12 +1,13 @@
|
||||
import * as strava from './strava.js';
|
||||
|
||||
async function main() {
|
||||
print('handler running');
|
||||
let r = await strava.authorization_code(request.query.code);
|
||||
print('state =', request.query.state);
|
||||
print('body = ', r.body);
|
||||
if (request.query.state && r.body) {
|
||||
let shared_db = await shared_database('state');
|
||||
await shared_db.set(request.query.state, r.body);
|
||||
await shared_db.set(request.query.state, utf8Decode(r.body));
|
||||
}
|
||||
await respond({
|
||||
data: r.body,
|
||||
|
Loading…
Reference in New Issue
Block a user