Merge pull request #15655 from CartoDB/jb/fix-ip-429-error-message

Fix 429 error message in IP message
pull/15651/head
Jesús Botella 4 years ago committed by GitHub
commit 502b15705e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -176,9 +176,9 @@ export default {
},
onIPRemoved ({ removedElement }) {
this.getCurrentIPs()
.then(() => {
const newIPList = new Set(this.ipList);
return this.$store.state.client.directDBConnection().getIPs(
(_1, _2, data) => {
const newIPList = new Set(data.ips);
newIPList.delete(removedElement);
this.$store.dispatch('directDBConnection/ip/set', Array.from(newIPList));

@ -25,7 +25,7 @@ export function setIPs (context, ips) {
function (err, _, data) {
if (err) {
const errorMessage =
(data.responseJSON && data.responseJSON.errors && data.responseJSON.errors.ips.join('. ')) ||
(data.responseJSON && data.responseJSON.errors && data.responseJSON.errors.ips && data.responseJSON.errors.ips.join('. ')) ||
(data.responseJSON && data.responseJSON.errors) ||
data.responseText ||
data.statusText;

2
package-lock.json generated

@ -1,6 +1,6 @@
{
"name": "cartodb-ui",
"version": "1.0.0-assets.176",
"version": "1.0.0-assets.177",
"lockfileVersion": 1,
"requires": true,
"dependencies": {

@ -1,6 +1,6 @@
{
"name": "cartodb-ui",
"version": "1.0.0-assets.176",
"version": "1.0.0-assets.177",
"description": "CARTO UI frontend",
"repository": {
"type": "git",

Loading…
Cancel
Save