Skip to content

Commit

Permalink
message when there are no cards
Browse files Browse the repository at this point in the history
  • Loading branch information
justincy committed Aug 10, 2017
1 parent 8fa1bfb commit db2c30c
Showing 1 changed file with 7 additions and 3 deletions.
10 changes: 7 additions & 3 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -141,9 +141,13 @@ async function displayList(listId) {
const $list = $('#list').html('');

// Render cards
cards.forEach(c => {
$list.append(displayCard(c));
});
if(cards.length) {
cards.forEach(c => {
$list.append(displayCard(c));
});
} else {
$list.append('<p>Use the tools on the right to add a research task.</p>');
}
}

/**
Expand Down

0 comments on commit db2c30c

Please sign in to comment.