Skip to content

Commit

Permalink
Fixing 2 bugs that happen when fields are removed from table (#551)
Browse files Browse the repository at this point in the history
  • Loading branch information
mistercrunch committed Jun 2, 2016
1 parent 5f005d6 commit b5614a4
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion caravel/assets/javascripts/explore.js
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,8 @@ function initExploreView() {
function set_filters() {
for (var i = 1; i < 10; i++) {
var eq = px.getParam("flt_eq_" + i);
if (eq !== '') {
var col = px.getParam("flt_col_" + i);
if (eq !== '' && col !== '') {
add_filter(i);
}
}
Expand Down
2 changes: 1 addition & 1 deletion caravel/forms.py
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ def iter_choices(self):
d[value] = (value, label, selected)
if self.data:
for value in self.data:
if value:
if value and value in d:
yield d.pop(value)
while d:
yield d.popitem(last=False)[1]
Expand Down

0 comments on commit b5614a4

Please sign in to comment.