use clientSecret in login flow

This commit is contained in:
taehoon 2019-06-19 23:20:14 -04:00
parent c23228f196
commit 8a32731e4d
2 changed files with 4 additions and 2 deletions

View file

@ -26,9 +26,10 @@ const LoginForm = {
this.isTokenAuth ? this.submitToken() : this.submitPassword()
},
submitToken () {
const { clientId } = this.oauth
const { clientId, clientSecret } = this.oauth
const data = {
clientId,
clientSecret,
instance: this.instance.server,
commit: this.$store.commit
}

View file

@ -4,10 +4,11 @@ const oac = {
props: ['code'],
mounted () {
if (this.code) {
const { clientId } = this.$store.state.oauth
const { clientId, clientSecret } = this.$store.state.oauth
oauth.getToken({
clientId,
clientSecret,
instance: this.$store.state.instance.server,
code: this.code
}).then((result) => {