forked from MapComplete/MapComplete
Android: add passthrough pages
This commit is contained in:
parent
969ad74bd9
commit
a34abb702c
6 changed files with 104 additions and 0 deletions
11
app/land.ts
Normal file
11
app/land.ts
Normal file
|
@ -0,0 +1,11 @@
|
|||
import { OsmConnection } from "../src/Logic/Osm/OsmConnection"
|
||||
import Constants from "../src/Models/Constants"
|
||||
|
||||
console.log("Authorizing...")
|
||||
const key = Constants.osmAuthConfig.url + "oauth2_state"
|
||||
const st =window.localStorage.getItem(key )
|
||||
console.log("Prev state is",key, st)
|
||||
new OsmConnection().finishLogin((_, token: string) => {
|
||||
console.log("Login finished, redirecting to passthrough")
|
||||
window.location.href = "https://app.mapcomplete.org/passthrough.html?oauth_token="+token
|
||||
})
|
Loading…
Add table
Add a link
Reference in a new issue