Skip to content

Commit

Permalink
Merge pull request #28 from luniehq/fabo/gaiav2
Browse files Browse the repository at this point in the history
Fabo/change schema names in db access queries
  • Loading branch information
faboweb authored Oct 21, 2019
2 parents bf99e81 + 656ac8d commit 5123ab9
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
2 changes: 1 addition & 1 deletion lib/luniedb-source.js
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ class LunieDBAPI extends RESTDataSource {
? `(where: {operator_address: {_eq: "${validatorId}"}})`
: ''
return await this.getData(
networkID.replace('-', '_') + '_validatorprofiles',
networkID.replace(/-/g, '_') + '_validatorprofiles',
selection
)
}
Expand Down
8 changes: 4 additions & 4 deletions lib/queries.js
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,9 @@ const queries = {
}
}
`,
gaia_testnet_validatorprofiles: selection => `
cosmos_hub_testnet_validatorprofiles: selection => `
query {
gaia_testnet_validatorprofiles${selection} {
cosmos_hub_testnet_validatorprofiles${selection} {
details
name
picture
Expand All @@ -48,9 +48,9 @@ const queries = {
}
}
`,
cosmoshub_validatorprofiles: selection => `
cosmos_hub_mainnet_validatorprofiles: selection => `
query {
cosmoshub_validatorprofiles${selection} {
cosmos_hub_mainnet_validatorprofiles${selection} {
details
name
picture
Expand Down

0 comments on commit 5123ab9

Please sign in to comment.