fix: remove unnecessary code

This commit is contained in:
José Oliveira 2022-04-26 22:21:58 +01:00 committed by siiky
parent 81ef96a670
commit d72fc97f98

View file

@ -17,15 +17,12 @@ function request (graphqlQuery, token) {
'content-type': 'application/json',
'Authorization': `Bearer ${token}`
}
return Promise.resolve(true)
.then(() => {
return axios({
method: 'post',
url: URI,
headers: headers,
data: graphqlQuery
})
})
.then(r => {
if (r.error) throw r.error
return r.data
@ -45,7 +42,6 @@ function getGaloyAccount (token) {
'operationName': 'me',
'query': `query me {
me {
createdAt
defaultAccount {
defaultWalletId
wallets {
@ -55,7 +51,6 @@ function getGaloyAccount (token) {
transactions {
edges {
node {
createdAt
direction
id
settlementAmount
@ -91,9 +86,6 @@ function getGaloyAccount (token) {
}
}
id
phone
twoFAEnabled
username
}
}`,
'variables': {}
@ -269,7 +261,7 @@ function getStatus (account, tx, requested, settings, operatorId) {
return 'notSeen'
}
const externalCryptoCode = coinUtils.getExternalCryptoCode(cryptoCode)
const address = coinUtils.parseUrl(address)
const address = coinUtils.parseUrl(toAddress)
return checkCryptoCode(cryptoCode)
.then(() => getGaloyAccount(account.apiKey))
.then(galoyAccount => {