Skip to content

Commit

Permalink
change a var name
Browse files Browse the repository at this point in the history
  • Loading branch information
mose committed Apr 1, 2016
1 parent 2d188c5 commit 91e9b8f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions app/public/js/farms.js
Original file line number Diff line number Diff line change
Expand Up @@ -51,19 +51,19 @@ ready( () => {
var Farm = {
show: function(el) {
addClass(meat, 'wait');
farm = el.dataset.item;
fetch('/v1/' + base + '/farm/' + farm, auth_header()).
focused = el.dataset.item;
fetch('/v1/' + base + '/farm/' + focused, auth_header()).
then(res => res.json()).
then(j => {
if (j.error !== undefined) {
show_error(meat, j['error']);
} else {
build_list(meat, farm, j);
build_list(meat, focused, j);
Array.prototype.forEach.call(farms, (item, i) => {
removeClass(item, 'focus');
});
addClass(el, 'focus');
update_footer('/v1/' + base + '/farm/' + farm);
update_footer('/v1/' + base + '/farm/' + focused);
}
removeClass(meat, 'wait');
});
Expand Down

0 comments on commit 91e9b8f

Please sign in to comment.